Qlik Community

New to QlikView

Discussion board where members can get started with QlikView.

Announcements
Qlik Analytics Tour 2020 Online. Begins August 10th. Register Today
cancel
Showing results for 
Search instead for 
Did you mean: 
Highlighted
Creator III
Creator III

Set Analysis multiple condition issue

Hi there,

 

Can someone tell my what is wrong with the below set analysis expression ?

I have a Straight table and I am trying to use this expression to restrict the data 

If I use the below formula all the restriction before  Actual_End.RelativeMonth = {'0'}> + <WO_Actual_End_Date = {'-'} are ignored and I don't understand why.

Count({<Customer = {'ABC'}, [Ticket Category] = {'Incident'}, Created.RelativeMonth -= {'0'}, Actual_End.RelativeMonth = {'0'}> + <WO_Actual_End_Date = {'-'} >} WO_Created_Date)

The logic is:

if Customer = ABC and Ticket Category = Incident and Created Month is NOT Current Month( I take this from Calendar) and The End date is Current month or End Date field is " - ", count the WO_Created_Date.

Thanks in advance

Labels (1)
1 Solution

Accepted Solutions
Highlighted

Re: Set Analysis multiple condition issue

May be try this

Count({<Customer = {'ABC'}, [Ticket Category] = {'Incident'}, Created.RelativeMonth -= {'0'}>*(<End.RelativeMonth = {'0'}> + <End_Date = {'-'}>)}Created_Date)

or this

Count({<Customer = {'ABC'}, [Ticket Category] = {'Incident'}, Created.RelativeMonth -= {'0'}, End.RelativeMonth = {'0'}> + <Customer = {'ABC'}, [Ticket Category] = {'Incident'}, Created.RelativeMonth -= {'0'}, End_Date = {'-'}>}Created_Date)

View solution in original post

5 Replies
Highlighted

Re: Set Analysis multiple condition issue

It might be easy to resolve if you are able to share a sample for us to see.

Highlighted
Creator III
Creator III

Re: Set Analysis multiple condition issue

Sorry but I can't copy and paste the code from my app.

I don't understand how to use "OR" in set analysis 

I have found something like End.RelativeMonth = {'0'}> + <End_Date = {'-'}  but if I put this condition all the other condition are not counted.

Count({<Customer = {'ABC'}, [Ticket Category] = {'Incident'}, Created.RelativeMonth -= {'0'}, End.RelativeMonth = {'0'}> + <End_Date = {'-'} >}Created_Date)

Created.RelativeMonth is a new field based on the master calendar and aso End.RelativeMonth.  

End_Date and Created Date are the fields which I use to create the masters calendars.

Highlighted

Re: Set Analysis multiple condition issue

May be try this

Count({<Customer = {'ABC'}, [Ticket Category] = {'Incident'}, Created.RelativeMonth -= {'0'}>*(<End.RelativeMonth = {'0'}> + <End_Date = {'-'}>)}Created_Date)

or this

Count({<Customer = {'ABC'}, [Ticket Category] = {'Incident'}, Created.RelativeMonth -= {'0'}, End.RelativeMonth = {'0'}> + <Customer = {'ABC'}, [Ticket Category] = {'Incident'}, Created.RelativeMonth -= {'0'}, End_Date = {'-'}>}Created_Date)

View solution in original post

Highlighted
Creator III
Creator III

Re: Set Analysis multiple condition issue

many thanks! all good now 🙂
Highlighted
Contributor
Contributor

Test

Just testing the discussion board