Search for grouped item sales report on forum, I did a grouped report but if you changed the @ for a manual CSV list it would achieve what it sounds like what you want.
I would change the report to be the same for “Group Sales by Amount, Group Sales by Quantity & Sales” as it is on the report.
[Group Sales by Amount:2, 1, 1]
{REPORT ORDER DETAILS:O.ItemGroup,O.ExactTotal.Percent.desc,O.ExactTotal.Sum:(ODI=True)}
>Total|{REPORT ORDER DETAILS:O.ExactTotal.Sum:(ODI=True)}
[Group Sales by Quantity:2, 1, 1]
{REPORT ORDER DETAILS:O.ItemGroup,O.Quantity.Percent.desc,O.Quantity.Sum:(ODI=True)}
>Total||{REPORT ORDER DETAILS:O.Quantity.Sum:(ODI=True)}
[Sales:5, 2, 2,1]
@{REPORT ORDER DETAILS:O.MenuItemName,O.ExactTotal.Sum.desc:(ODI=True):{0}:,}
>{REPORT ORDER DETAILS:O.MenuItemName,O.Quantity.Sum.desc,O.ExactTotal.Sum.desc:(ODI=True) and O.MenuItemName="$1"}
{REPORT ORDER DETAILS:' '+[O.PortionName],O.Quantity.Sum.desc,O.ExactTotal.Sum.desc:(ODI=True) and O.MenuItemName="$1":2}
If I wanted to do that I would look to try adding a custom product tag called say ‘Report on Group’ and put a value like Y in each product wanting to be reported then add a constraint on the report for Item tag = Y which sure can be done on report order details.
It’s a little more specific that by group but would give granular control over what’s included on report and simplify the report expression else you would probably have to do GroupCode=X OR GroupCode=Y OR etc etc specifying each GroupCode.
Just to let everyone interested know I settled on the following report, it does take some time to generate but the results are good, sales divided by group name:
Cant hurt to have another report give it a try!
@{REPORT ORDER DETAILS:O.ItemGroup.asc,O.ExactTotal.Sum::{0}:,}
@{REPORT ORDER DETAILS:O.MenuItemName,O.ExactTotal.Sum.desc:(ODI=True):{0}:,} [$1 Sales:7, 2, 2, 3]
{REPORT ORDER DETAILS:O.MenuItemName,OS.NewBook GLA,O.Quantity.Sum.desc,O.ExactTotal.Sum.desc:(ODI=True) and O.MenuItemName=“$2” and (MG=$1)}
{REPORT ORDER DETAILS:’ ‘+[O.PortionName],’',O.Quantity.Sum.desc,O.ExactTotal.Sum.desc:(ODI=True) and O.MenuItemName=“$2” and (MG=$1) and O.PortionName!=“Normal”}
Total $1||{REPORT ORDER DETAILS:O.Quantity.Sum,O.ExactTotal.Sum:(ODI=True) and (MG=$1)}