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

Announcements
Qlik Open Lakehouse is Now Generally Available! Discover the key highlights and partner resources here.
cancel
Showing results for 
Search instead for 
Did you mean: 
kelly_oakley
Contributor II
Contributor II

Nested IF Statement to create Bandings

Hi,

I wonder if you can help me. I am trying to get Qlik to look at values of Items and put them into Bandings.

I have created a Nested If statement but Qlik is coming up with Error in Expression.

What am I doing wrong?

=if(JobPartCostAmount<80,'Less than £80',
if(JobPartCostAmount>80.01 and JobPartCostAmount<300),'£80-£300',
if(JobPartCostAmount>300.01 and JobPartCostAmount<600),'£300-£600',
if(JobPartCostAmount>600.01 and JobPartCostAmount<900),'£600-£900',
if(JobPartCostAmount>900.01,'Greater than £900'))

Thanks

Labels (1)
2 Replies
sunny_talwar

Try this

=If(JobPartCostAmount < 80, 'Less than £80',
 If(JobPartCostAmount < 300, '£80-£300',
 If(JobPartCostAmount < 600, '£300-£600',
 If(JobPartCostAmount <= 900, '£600-£900',
 If(JobPartCostAmount > 900.01, 'Greater than £900')))))
kelly_oakley
Contributor II
Contributor II
Author

Hi Sunny,

You are an absolute star thank you so much Woman Happy