Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi gurus,
I know the only solution to solve my problem is to use aggr, but I have not use aggr before and have no idea on how to make it works
Type | Number of People | Vacation Stay in Days | Total Days(Column(2) * Column(3)) |
---|---|---|---|
Male | 4 | 5 | 20 |
Male | 4 | 1 | 4 |
Male | 5 | 12 | 60 |
Male | 3 | 3 | 9 |
Male | 7 | 2 | 14 |
The sum of Total Day will be 107 after adding up the total days. This figure of 107 is the desired output for me for a specific column.
Here is my desired table layout
Type | Total Number of People | Total Days |
---|---|---|
Male | 4+4+5+3+7 = 23 | 107 |
Female | 12 | 90 |
Others | 7 | 31 |
I believe I need to use aggr but anybody can help me out on the expression that I should use?
Thanks very much in advance
Try
=sum( aggr( Days*sum(Box), Month,Type,Days ))
Sorry about the duplicate post.
The expression diden give me the result that I want, did you manage to get the value using the example file?
Yes, I got 30, 44, ...
Check attached.
you got it correct. gosh but not me, I will try to find the logic behind these in 9 hours time, got to sleep now. thanks alot for ur help. basically aggr expression, you have to list out the expression follow by the dimension of the virtual table?
Hi guys,
Not sure if this is bug or something, I managed to solve this problem thanks to swuehl, he attached a working file for reference.
I am wondering is aggr a realiable code to use? As I copied the table to another file, the value changed with the same database, i did not change any script too.
When i upload the report to the server, the figure of the aggr column changed too.
why is this so? is it a bug?