Hi there,
I'm running into an issue where I'm trying to retrieve the gross margins for a particular subset of data, and also return the parent of each subset gross margin as well.
The individual items are fine and working, but the parent calculation is adding up the percentages, or returning a /0 error instead of returning the gross margin for the parent set. For example
(All Part of Group A)
Product 1 Sales 10 Cost 8 GM 20%
Product 2 Sales 20 Cost 18 GM 10%
Product 3 Sales 10 Cost 9 GM 10%
Group A Total (should be ) Sales 40 Cost 35 GM 12.5%
Instead its returning Sales 40 Cost 35 GM 40%<--- Adding the Gross Margins of the previous numbers
Please help!
Try changing the aggregate function of the total data item to 'Aggregate'
That did not work. It was still showing the proper amounts for the Sales and COGS, but did not have the proper Gross Margin based off of that.
I've added screen shots to show the issue.
See the attached sample report. Check the property of Aggregate data item.
Check the solve order for GM data item. It should be set to 2, or a higher number than the solve order on the total rows.