Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Want to see what's currently in public preview? We've pulled it all together in one place. Check it out here
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

if condition

Hello guys,

how to make this condition using if..else :

profit range between 1000 to 2000 then status is : acceptable.

profit range between 2000 to 3000 then status is : above average.

profit range between 3000 to 4000 then status is : exceeds expectation.

thanks

Labels (1)
3 Replies
rajeshvaswani77
Specialist III
Specialist III

if((prange>=1000 and prange<=2000), 'acceptable',if((prange>2000 and prange<=3000),'above average',if((prange>3000 and prange<=4000),'exceeds expectation','NA')))

jagan
Partner - Champion III
Partner - Champion III

Hi,

Use this expression

If (profitRange > 3000 AND profitRange <= 4000, 'exceeds expectation',

     If (profitRange > 2000 AND profitRange <= 3000, 'above average',

     If (profitRange > 1000 AND profitRange <= 2000, 'acceptable', 'N/A')))

Regards,

Jagan.

CELAMBARASAN
Partner - Champion
Partner - Champion

Hi,

     I think this expression is enough for you.

    

If (profitRange > 3000, 'exceeds expectation',

     If (profitRange > 2000 , 'above average',

     If (profitRange > 1000, 'acceptable', 'N/A'))) [as FieldName] use this alias part if your using it in load script.

Celambarasan