Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi,
How to have 'OR' condition in Qlikview? i.e like 'Col A=100 or ColB='John'. I don't see that option in Button. How else can we approach this?
Thanks,
Sudha.
That cant be done with only making selections. You can use set analysis expressions. Alternate states may come in useful too. A set analysis expression would look like sum({<[Col A]={100}>+<[Col B]={'John'}>}Amount). If you use alternate states so you can make selections that don't influence each other the set analysis expression would look like sum({AltStateA+AltStateB}Amount)
Try Selecting in your ID field something like this string:
='=COL_A= 100 OR COL_B=' & chr(39) & 'John' & chr(39)
Hi,
Thanks for your suggestions. I would like to do this in Button. Since this involves two fields, what should I give in 'Field' box in Button action/Select in Field.
For this: ='=COL_A= 100 OR COL_B=' & chr(39) & 'John' & chr(39) to work, you'll want the field to be whatever field you want it to operate on.
If I have a table of people with PERSON_ID as the primary key and I want to return all the people that meet that OR criteria, I would make the field to select in PERSON_ID. Make sense?
Thanks! What if I have something like 'Col A='John' and ColB is not null' Is there a way to handle this?
Essentially the exact same way, you are just trying to select the string =Col A = 'John' AND NOT ISNULL(ColB)
It gets a little messy with the single quotes but it would be something like
='=COL_A=' & chr(39) & 'John' & chr(39) & ' AND NOT ISNULL(COL_B)'
Thank you for your prompt help! It's working fine.
Hi,
Could you please help me how to add a third condition to this and also please help me with the syntax for handling not equal to.
='=TEST_CASE_STATUS=' & chr(39) & 'Expired' & chr(39) & ' OR NOT ISNULL(REASON_FOR_DELAY)' & 'AND ' & '=RULE_DESIGNATION=' & chr(39) & '<>Manual' & chr(39)
I have the following questions:
1. How to club first and second condtion i.e Test_case_status='Expired' or REASON_FOR_DEALY is not null. Just a bracket will work?
2. How to add a third condition to this? ...& 'AND ' & '=RULE_DESIGNATION=' & chr(39) & '<>Manual' & chr(39) - This does not work
3. How to handle not equal to? '=RULE_DESIGNATION=' & chr(39) & '<>Manual' & chr(39) - This does not work too.