• Hi Jack,

    Many thanks for that but unfortunately it's not what the user wants!

    The total turnover figure represents the total turnover across all sectors, not the specific sector. So if someone has bought sky hooks, the user don't want to know how much they spent on sky hooks but how much they spent overall. So what they are looking for is who bought items from sectors x and y, how much their total spend was, and how much the grand total of the total spend was.

    So regardless of how many of the chosen sectors the customer has purchased products in the customer only appears once (hence the grouping) and the totalturnover figure only appears once. And the grand total should be the sum of the figures displayed.

    Yes, I know it doesn't make a lot of sense but that is what the user wants!

    The code to mimic the output from the SP appears earlier in the thread?