Qlik Community

QlikView App Dev

Discussion Board for collaboration related to QlikView App Development.

Announcements
QlikWorld 2022, LIVE in Denver CO., May 16-19, 2022. REGISTER NOW TO RECEIVE EARLY BIRD PRICING
cancel
Showing results for 
Search instead for 
Did you mean: 
praveen1108
Creator
Creator

How to use an expression which has set analysis in it as Filter

Hello All,

I have 2 Measures which are calculated using set analysis and based on those calculations i wanted to create a filter.

For Example:

Measure1:

Count({<STATUS={'APPROVED','SUBMIT'},[CTime={'XYZ'}>}  [TicketNo])

Measure2:

Count({<[FLAG]={'OPEN'},STATUS={'APPROVED','SUBMIT'}>}  [TicketNo])


Now i want to write an expression for Filter as Closed and Open on below logic

If(Count({<STATUS={'APPROVED','SUBMIT'},[CTime={'XYZ'}>}  [TicketNo])<>0,'Closed',

If(Count({<[FLAG]={'OPEN'},STATUS={'APPROVED','SUBMIT'}>}  [TicketNo])=0,'Open'))


Some one please suggest me how we can do this?


Regards,

PK



5 Replies
sunny_talwar

Not entirely sure I understand. Can you please elaborate?

ramoncova06
Specialist III
Specialist III

What are you trying to do with the second set analysis, identify which ones do not have that status ?

if that is the case then you could exclude those values from the set analysis

If(Count({<STATUS={'APPROVED','SUBMIT'},[CTime={'XYZ'}>}  [TicketNo])<>0,'Closed',

If(Count({<[FLAG]={'OPEN'},STATUS-={'APPROVED','SUBMIT'}>}  [TicketNo])<>0,'Open'))



praveen1108
Creator
Creator
Author

Whatever the status it is, Please don't look at the logic as i was trying to just give an example. i just wanted to use expressions like that and want to write an expression in filter to show Closed and Open Status.Is it Possible?

ramoncova06
Specialist III
Specialist III

you can write expression to do these kind of things, but this can have a very high performance cost, I would suggested getting as many of these in you data model instead of using the front end for them

praveen1108
Creator
Creator
Author

Still can you just let me know how we can wirte an expression.just wanted to see..