Any invoices that are created are going to retained earnings and not to sales. Why is this?
Transactions that go to P&L accounts also create entries that go to Retained Earnings. This is to maintain the Perpetual nature of the database file.
To troubleshoot your issue please provide a snip of the edit screen of a problem sales invoice.