Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
I have the below expression in the chart properties and I would like to add in the scrip. Can someone show me the best approach?
Expression in Chart - count({<Status={[Pended]}>}distinct ID)
how would that look in the scrip? Can I use a IF Statement, this is what I have below...
Count(IF(Status= 'Pended','')) as TotalPends
Does this look like what you want?
Script:
TEST:
LOAD *,
1 as COUNTstatus,
If(STATUS = 'PENDING', 1, 0) as COUNTPENDS;
LOAD * Inline [
ID, DESCRIPTION, STATUS
1, ONE, PENDING
2, TWO, APPROVED
3, THREE, PENDING
4, FOUR, DENIED
5, FIVE, PENDING
6, SIX, APPROVED
7, SEVEN, PENDING
];
Yes but can we show a total in the stragiht table as well?
Total Count Status
Total CountPends
Here you go
I appreciate you taking the time to help resolve my issue. That was painful for me, in the future I'll be more clear.
Don't worry, as long as we were able to work out a solution, its all good