Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Please convert the below statement into set anlaysis expression
if(SCV_LAST_INS_REPAIR_INDICATOR='Y' and (SCV_LATEST_INSURRANCE_DATE-SCV_LAST_INSURRANCE_DATE)<=90,'Pass'
Thanks
AS
HI ANita,
I believe you have a misguided understanding of set analysis.
Extracted from Qlik Help:
Set analysis and set expressions ‒ QlikView
"Normally, when you make a selection, aggregation functions, such as Sum, Max, Min, Avg, and Count aggregate over the selections that you have made: the current selections. Your selections automatically define the data set to aggregate over. With set analysis you can define a group that is independent of the current selections. This can be useful if you want to show a particular value, for example, the market share of a product across all regions, irrespective of the current selections."
So, if your not aggregating the data in some way (as examplified by the functions above) you should do what you need in the LOAD script rather than set analysis.
Something like
Data:
Load
SCV_LAST_INS_REPAIR_INDICATOR,
SCV_LATEST_INSURRANCE_DATE,
SCV_LAST_INSURRANCE_DATE,
if
(
SCV_LAST_INS_REPAIR_INDICATOR='Y'
and
(SCV_LATEST_INSURRANCE_DATE-SCV_LAST_INSURRANCE_DATE)<=90,
'Pass',
'Don't Pass'
) as Description
From [Whatever]
Hope it helps.
Felipe.
Its look like you want to assign flag as pass or fail based on some condition.
To achieve this you will not require any set analysis.
You can simply achieve it at script level.
Thanks,
Vishal
@Felip : Thanks for simplifying the code , it did help out to lessen the access time , as we are looking into performance optimization.
Any other measures u suggest , might help out in perf.. optimization of the reports .
Thanks ,
AS@