Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi,
I have below script in qvw. when I reload I can able to see in Flag column only START and GONE. Remaining are not loading into Flag column. Please can anyone suggest me is there any wrong in below script?
If (MixMatch(NAME,'XX',
'YY',
'ZZ',
'AA',
'BB',
'CC',
'DD',
'EE',
'FF',
'GG',
'HH',
'II',
'JJ',
'KK',
'LL',
'MM',
'NN',
'OO',
'PP',
'QQ,
'RR',
'SS',
'TT',
'UU',
'VV',
'WW'),Dual('START',1),
If(MixMatch(NAME,'GONE'),Dual('GONE',2),
If(MixMatch(NAME,'QQ,
'RR',
'SS',
'TT',
'UU'),Dual('APP',3)
If(MixMatch(NAME,'XX',
'YY',
'ZZ',
'AA',
'BB',
'CC',
'DD',
'EE',
'FF',
'GG',
'HH',
'II',
'JJ',
'KK',
'LL',
'MM',
'NN',
'OO',
'PP',
'VV',
'WW'),Dual('PROCESS',4),
If(MixMatch(NAME,
'YY',
'ZZ',
'AA',
'BB',
'CC',
'DD',
'EE',
'FF',
'GG',
'HH',
'II',
'JJ',
'KK',
'LL',
'MM',
'NN',
'OO',
'PP',
'QQ),Dual('CON',5)))))) as Flag
Thanks.
tried this. still showing same 0%
Few things to check:
I have tried in pivot table. when I used the below expression in text object it is working. only in chart it is not working.
=Count({<FlagNew= {'START'}>} FlagNew), does this work alone as well? =Count({<FlagNew= {'GONE'}>} FlagNew)
yes alone both working in text object. but alone both are not working in chart.
sorry I thought you want me to use in chart. so, I have used in chart earlier.
EDIT: I have two dimensions as below in pivot chart
FlagNew
Month
Can I suggest you changing your model from current one to a new model?
OriginalTable
LOAD *, If(MixMatch(NAME,'XX','YY','ZZ','AA','BB','CC','DD','EE','FF','GG','HH','II','JJ','KK','LL','MM','NN','OO','PP','QQ,'RR','SS','TT','UU','VV','WW'), 1, 0) as START_Flag,
If(MixMatch(NAME,'GONE'), 1, 0) as GONE_Flag,
If(MixMatch(NAME,'QQ,'RR','SS','TT','UU'), 1, 0) as APP_Flag,
If(MixMatch(NAME,'XX','YY','ZZ','AA','BB','CC','DD','EE','FF','GG','HH','II','JJ','KK','LL','MM','NN','OO','PP','VV','WW'), 1, 0) as PROCESS_Flag,
If(MixMatch(NAME,'YY','ZZ','AA','BB','CC','DD','EE','FF','GG','HH','II','JJ','KK','LL','MM','NN','OO','PP','QQ), 1, 0) as CON_Flag,
If(MixMatch(NAME,'XX','YY','ZZ','AA','BB','CC','DD','EE','FF','GG','HH','II','JJ','KK','LL','MM','NN','OO','PP','QQ,'RR','SS','TT','UU','VV','WW', 'GONE'), 1, 0) as SUCCESS_FLAG;
LOAD allYourFields
FROM source
and try this expression:
=Sum(START_Flag)/Sum(GONE_Flag)
EDIT: I have two dimensions as below in pivot chart
FlagNew
Month
Ah, ok.
The FlagNew dimension will prevent the two expressions to be evaluated as requested in the same line, unless...
=Count({<FlagNew= {'START'}>} TOTAL<Month> FlagNew)
/
Count({<FlagNew= {'GONE'}>} TOTAL<Month> FlagNew)
Thanks. I have tried this. showing percentage as all 100% and showing 1 in START_Flag and 1 in GONE_Flag.
remaining flag column values showing as zeroes.
Hi,
Please post a sample file with data
Thanks. I have tried this. I can able to see the percentage. is there any way in pivot table to show GONE percentage related to GONE column line , START percentage to sow only to START column line and so on. at present it is showing as below
MONTH | Oct 2013 | Oct 2013 | Oct 2013 | Oct 2013 | Nov 2013 | Nov 2013 | Nov 2013 | Nov 2013 |
FlagNew | Count | GONE % | APP % | START % | Count | GONE % | APP% | START % |
START | 3 | 67% | 22% | 11% | 18 | 65% | 27% | 8% |
GONE | 6 | 67% | 22% | 11% | 34 | 65% | 27% | 8% |
APP | 1 | 67% | 22% | 11% | 4 | 65% | 27% | 8% |
PROCESS | 2 | 67% | 22% | 11% | 14 | 65% | 27% | 8% |
CON | 2 | 67% | 22% | 11% | 14 | 65% | 27% | 8% |
SUCCESS | 9 | 67% | 22% | 11% | 52 | 65% | 27% | 8% |
but I want the pivot table to show as below
MONTH | Oct 2013 | Oct 2013 | Nov 2013 | Nov 2013 |
FlagNew | Count | % | Count | % |
START | 3 | 11% | 18 | 8% |
GONE | 6 | 67% | 34 | 65% |
APP | 1 | 22% | 4 | 27% |
PROCESS | 2 | 50% | 14 | 78% |
CON | 2 | 24% | 14 | 90% |
SUCCESS | 9 | 10% | 52 | 100% |
Is there any way to do this. Please help.
It would be more than helpful if you post your current working sample. It's kind of confusing looking at tables with numbers without knowing the current implemented expressions.
(I believe you are not using
=Count({<FlagNew= {'START'}>} TOTAL<Month> FlagNew)
/
Count({<FlagNew= {'GONE'}>} TOTAL<Month> FlagNew)
for START %, right?
)
In general, I believe you want only a single expression for %, and this expression needs to consider the current dimension value for FlagNew. So at least the numerator should not use a set expression that makes a selection in that field.
Again, I somehow lost what you want to calculate, your current Count numbers and % does not show what I think you requested last (maybe I missed a new requirement).
I assume you need an expression like
=Count(FlagNew) / Count({<FlagNew= {'GONE'}>} TOTAL<Month> FlagNew)
but I am pretty much guessing, you need to give more information if you want us to help you.
I am using the below expression
=Count({<FlagNew= {'START'}>} TOTAL<Month> FlagNew)
/
Count({<FlagNew= {'GONE'}>} TOTAL<Month> FlagNew)
for START %
I am getting expected result when I used above expression. All I need is percentages are showing multiple times for all rows. Instead of the I need START percentage next to START value. GONE percentage next to GONE value, APP percentage next to APP value and so on.
is it possible please let me know.