Skip to main content
Announcements
Have questions about Qlik Connect? Join us live on April 10th, at 11 AM ET: SIGN UP NOW
cancel
Showing results for 
Search instead for 
Did you mean: 
suresh_qv50
Creator
Creator

SetAnalysis usage in Qliksense Script Getting Error

Hi Every One,

Am facing issue when using set analysis and aggr in qliksense script, Always getting script error for these expresions

Aggr:

if(aggr(count(TransactionId),BankName)< 500,'Others',left(BankName,10))

Set Analysis:

Temp:

load

sum({<PL.paidindays = {'-14'}>}PL.DueAmt) as [Statement DueAmt] resident PaymentLiquidation;

if i use any set analysis expresions like Qlikview always getting like this

sum({<PL.paidindays = {'-14'}>}PL.DueAmt) as [Statement DueAmt]

Getting Red Mark after sum .. Can any one give me alternative expression in case of Aggr and Set Analysis.

Regards

suresh

3 Replies
marcus_sommer

Set analysis and aggr-functions are features from the gui - they aren't available on script-level. You will need for the aggregations group by loadings and if-loops for for the conditions.

- Marcus

suresh_qv50
Creator
Creator
Author

We are using nested if conditions to achieve cyclic functionality it leads poor performance,  Is there any optimised expression for these type of expression

IF($(vDim)=1,Year,if($(vDim)=2,Month,if($(vDim)=3,Date,if($(vDim)=4,store))))

Regards

suresh

marcus_sommer

Instead of nested if-lops you could use pick(match()) - take a look here: is nested if allowed in Average()?

- Marcus