My goal is to apply formulas created in row definitions only at the lowest level of the report tree structure, ensuring that higher levels simply aggregate the numbers from below.
Here's a specific example to illustrate my issue:
I'm managing the financial statements for a hotel group.
One hotel accounts for 'available rooms per day' in account S820 and 'operating days in a month' in account S830.
For instance, S820 stores the number of daily sellable rooms as 10 (@110), and S830 shows the opening days in a month as 20 (@120).
I've calculated the total sellable rooms in a month in @130 as @110*@120, which logically equals 200.
Now, if there's a second hotel with S820 = 15 and S830 = 30, the sum there is 15*30 = 450.
However, when moving to a consolidated level, the calculation goes awry:
@110 sums to 25, and @120 to 50, leading to an incorrect calculation of 1250, whereas the correct sum should be 10*20 + 15*30 = 650.
I tried using a formula to detect if I'm at a higher unit level (IF @UNIT) to adjust the calculation by dividing the days by the number of hotels.
Yet, this approach also fails because it results in:
@110 = 25
@120 = 50/2 = 25
And thus, 25*25 = 625, which is not the correct total of 650.
I'm seeking a simple solution to accurately calculate these numbers at the consolidated level without distorting the individual hotel data.
Any assistance would be greatly appreciated. Thank you.


Report
All responses (
Answers (