01
About this report
The main income statement totals, one row per posting period for the last 24 months, in base currency from the primary accounting book. The columns are revenue, cost of sales, gross profit, operating expenses, other income and expense as one net figure, net income, gross margin and net margin.
When you group by Quarter or Year, margins are recalculated from the totals, not averaged. The report is built for dashboard tiles and trend lines. For the account-level statement, use Income statement by month.
02
Sample preview
Fictional figures in the shape you will see. Yours come from your account.
| Month | Revenue | Cost of sales | Gross profit | Operating expenses | Other income and expense | Net income | Gross margin | Net margin |
|---|---|---|---|---|---|---|---|---|
| 2026-06 | 588,200 | 196,400 | 391,800 | 301,250 | -2,100 | 88,450 | 0.67 | 0.15 |
| 2026-07 | 552,900 | 190,100 | 362,800 | 296,800 | 850 | 66,850 | 0.66 | 0.12 |
| 2026-08 | 600,750 | 201,900 | 398,850 | 305,120 | -1,220.80 | 92,509.20 | 0.66 | 0.15 |
| 2026-09 | 571,300 | 198,200 | 373,100 | 299,400 | 310 | 74,010 | 0.65 | 0.13 |
03
The SuiteQL
This is the query each report runs. Read it, copy it, or change it after import.
SELECT period,
revenue,
cost_of_sales,
revenue - cost_of_sales AS gross_profit,
operating_expenses,
other_net,
revenue - cost_of_sales - operating_expenses + other_net AS net_income,
(revenue - cost_of_sales) / NULLIF(revenue, 0) AS gross_margin,
(revenue - cost_of_sales - operating_expenses + other_net) / NULLIF(revenue, 0) AS net_margin
FROM (SELECT TO_CHAR(p.startdate, 'YYYY-MM') AS period,
SUM(CASE WHEN a.accttype = 'Income' THEN -tal.amount ELSE 0 END) AS revenue,
SUM(CASE WHEN a.accttype = 'COGS' THEN tal.amount ELSE 0 END) AS cost_of_sales,
SUM(CASE WHEN a.accttype = 'Expense' THEN tal.amount ELSE 0 END) AS operating_expenses,
SUM(CASE WHEN a.accttype IN ('OthIncome', 'OthExpense') THEN -tal.amount ELSE 0 END) AS other_net
FROM transactionaccountingline tal
JOIN accountingbook ab ON ab.id = tal.accountingbook AND ab.isprimary = 'T'
JOIN transaction t ON t.id = tal.transaction
JOIN account a ON a.id = tal.account
JOIN accountingperiod p ON p.id = t.postingperiod
WHERE tal.posting = 'T'
AND a.accttype IN ('Income', 'COGS', 'Expense', 'OthIncome', 'OthExpense')
AND p.startdate >= ADD_MONTHS(TRUNC(SYSDATE, 'MM'), -23)
AND p.startdate <= SYSDATE
GROUP BY TO_CHAR(p.startdate, 'YYYY-MM'))
ORDER BY period04