Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
I have a Pivot table that I am trying to remove the dashes with zeros, the scenario is if the Salesperson has not sold a shirt (etc) the pivot table is entering a dash as no value against the column of shirts. I need to change this, so it brings back a zero (0) value instead of a dash (-). Does anyone have any suggestions on how to do this (Please)?
try this
rangesum(expression,0)
These null values indicate that there is no relation between Column dimension and row Dimension.
Example:-
According to your dataset there are No Shirts, Corresponding to tuesday (Even before Set analysis).
add zero to to Items with null values like this
tab:
load Item,Day,Item&'|'&Day as Temp,sold;
load * inline
[
Item,Day,sold
suits,Mon,5
shirts,Mon,2
belts,Mon,2
suits,Tue,2
pants,Tue,5
socks,Tue,12
footwear,Tue,5
suits,Wed,2
shirts,Wed,2
belts,Wed,2
socks,Wed,2
footwear,Wed,2
suits,Thu,15
shirts,Thu,15
belts,Thu,12
suits,Fri,32
shirts,Fri,32
pants,Fri,12
belts,Fri,25
];
load 0 as dum AutoGenerate 0;
for each i in FieldValueList('Day')
Concatenate(tab)
load distinct Item,'$(i)' as Day,0 as sold
resident tab where not exists(Temp,Item&'|$(i)');
next i;
drop field dum;
tab1:
load Item,Day,sold
resident tab;drop table tab;