Skip to main content
Announcements
NEW: Seamless Public Data Sharing with Qlik's New Anonymous Access Capability: TELL ME MORE!
cancel
Showing results for 
Search instead for 
Did you mean: 
adminkare
Contributor III
Contributor III

Conditional Filter

hi, 

I created a table. Too many rows of tables. I have reduced the number of lines by giving condition 1 and 0.

Calculation:

if([DOGUM TARIHI]>='25.06.2000' and [DOGUM TARIHI]<='31.03.2001', 1,0)

Im sending screenshot.

I want to that with zero row... go about with 1 and 0 rows...

 

for exm:

Column1     Column2

       a                       1

       b                       0

 

Column2-> Measures     " if([DOGUM TARIHI]>='25.06.2000' and [DOGUM TARIHI]<='31.03.2001', 1,0) "

Column1-> Dimensions

 

Thx u..

1 Solution

Accepted Solutions
adminkare
Contributor III
Contributor III
Author

yes sir.

it was your solution.

thank you.

View solution in original post

7 Replies
pradosh_thakur
Master II
Master II

May be this 

 if([DOGUM TARIHI]>=date#('25.06.2000' ,'DD.MM.YYYY') and [DOGUM TARIHI]<=date#('31.03.2001','DD.MM.YYYY')  1,0) 

Learning never stops.
adminkare
Contributor III
Contributor III
Author

yes true. This is work... but:

I want to choose to 1 values... I send to screenshot. 5 row this. there is Only one  "1 values"...

 

for examle..

 if([DOGUM TARIHI]>=date#('25.06.2000' ,'DD.MM.YYYY') and [DOGUM TARIHI]<=date#('31.03.2001','DD.MM.YYYY')  1,0) 

after this work, will be result:

column1     column2

a                             1

b                              1

c                                1

d                               1

 

"if" condition, get  "0 values" rows too.

i dont want to "0 values" rows.. because  "0 values" have 1 million row...

 

thank you

 

pradosh_thakur
Master II
Master II

put a where condition like in script

where [DOGUM TARIHI]>=date#('25.06.2000' ,'DD.MM.YYYY') and [DOGUM TARIHI]<=date#('31.03.2001','DD.MM.YYYY') )

don't hard the value is my advice

Learning never stops.
pradosh_thakur
Master II
Master II

Else create a field in sxcript

 

if([DOGUM TARIHI]>=date#('25.06.2000' ,'DD.MM.YYYY') and [DOGUM TARIHI]<=date#('31.03.2001','DD.MM.YYYY')  1,0)  as flag

 

then in chart

sum({<flag={1}>}measure)

Learning never stops.
adminkare
Contributor III
Contributor III
Author

Tanks sir..

Its Be 🙂

 

pradosh_thakur
Master II
Master II

Please close the thread if your query is answered, else let me know.
Learning never stops.
adminkare
Contributor III
Contributor III
Author

yes sir.

it was your solution.

thank you.