Is it possible to create a SQL query in query generator that would produce the sales information described below. This information should be grouped by item group.
previous week's sales (saved sales orders during that week)
2. YTD SALES
sales from the beginning of a year up to last day of the week (saved sales orders)
3. YTD Invoicing
invoicing from the beginning of a year up to last day of the week (without VAT)
Sales margin from column 3. (YTD)
All open sales order that are not delivered yet.
The stock value.