Help with Mutiple Iif statements

whuegel

New Member
Joined
Aug 5, 2014
Messages
2
Hi I'm trying to build a query field that returns a label based on total sales of an account. When I try to embed multiple Iif's into a single statement I am recieving an error. Can you help me?

SALES TIER: IIf([SALES]>750000,"Tier 4 - >$750,000",IIf([SALES]<250000,"Tier 1 - <$250,000",IIf([SALES]>250000 And [SALES]<500000,"Tier 2 - $250,000 - $500,000",IIf([SALES]>500000 And [SALES]<750000,"Tier 3 - $500,000 - $750,000","ERROR"))))

In English:

If Sales > $750,000 return "Tier 4 - >$750,000"
If Sales < $250,000 return "Tier 1 - <$250,000"
If Sales are between $250,000 and $500,000 return "Tier 2 - $250,000 - $500,000"
If Sales are between $500,000 and $750,000" return "Tier 3 - $500,000 - $750,000"
 

Excel Facts

Copy PDF to Excel
Select data in PDF. Paste to Microsoft Word. Copy from Word and paste to Excel.
Hi whuegel and welcome to the forum :)

Would something like this work for you:

Code:
=IF(A1<250000,"Tier 1",IF(A1<500000,"Tier 2",IF(A1<750000,"Tier 3",IF(A1>=750000,"Tier 4"))))

?

I've used worksheet range A1 in place of your [SALES] so I could test it out.
 
Upvote 0
Hi whuegel and welcome to the forum :)

Would something like this work for you:

Code:
=IF(A1<250000,"Tier 1",IF(A1<500000,"Tier 2",IF(A1<750000,"Tier 3",IF(A1>=750000,"Tier 4"))))

?

I've used worksheet range A1 in place of your [SALES] so I could test it out.

Thanks!
 
Upvote 0

Forum statistics

Threads
1,215,266
Messages
6,123,962
Members
449,137
Latest member
yeti1016

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top