Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hello friends.
I am stuck off while doing calculation in pivot chart.
Please find below the table details with output. I have a table like this
LOAD * Inline [
ID,SubId,SubId2,Sale,sale,Stock
1001,a,a1,20,40,10
1001,b,b1,-20,40,60
1001,c,c1,30,40,60
1002,d,d1,30,60,70
1002,a,a1,40,60,80
1003,z,z1,-50,40,90
];
On front side i am creating pivot table.
Used one expression : (sum(Sale)+sum(sale))-sum(Stock) - Total Sale
Now I want output like this :
ID | SubId | SubId2 | Total Sale |
1001 | a | a1 | 50 |
1001 | b | b1 | -40 |
1001 | c | c1 | 10 |
1001 | Total | 60 | |
1002 | a | a1 | 20 |
1002 | d | d1 | 20 |
1002 | Total | 40 | |
1003 | z | z1 | -100 |
1003 | Total |
Here what i want to show in Total field ignore negative values consider only positive while doing totalling and if there is only negative value then total field should be null.
I am using dimensionality() function to do the same but not getting the desired result.
Please find attachment also.
Any help will be appreciable.
Regards
Mohit
Hi,
Well It was just suggestion. If particular field not necessary then avoid it.
Regards,
Agreed