Multiple if statements in one cell

mtetzlaf
mtetzlaf
edited 09/27/22 in Formulas and Functions

Hello - been struggling with this one, beginning to think it's not possible within smartsheet.

I am trying to create an IF statement where if you select a certain value from the dropdown column "Recruitment Team Alignment", it populates the "RTA Code" with a certain number. Here is the formula i've tried.. I'm worried it may be too long.. 18 different selections..


=IF([Recruitment Team Alignment]@row = "AMS Central", 100, IF([Recruitment Team Alignment]@row = "AMS Sales", 200), IF([Recruitment Team Alignment]@row = "AMS Corporate Functions", 300), IF([Recruitment Team Alignment]@row = "AMS ONEx", 400, 0), IF([Recruitment Team Alignment]@row = "AMS Engineering1", 500), IF([Recruitment Team Alignment]@row = "AMS Engineering2", 600), IF([Recruitment Team Alignment]@row = "AMS Engineering3"), 700), IF([Recruitment Team Alignment]@row = "AMS Director Plus", 800), IF([Recruitment Team Alignment]@row = "AMS Sourcing", 900), IF([Recruitment Team Alignment]@row = "APJC", 1000), IF([Recruitment Team Alignment]@row = "EMEA", 1100), IF([Recruitment Team Alignment]@row = "ETR", 1200), IF([Recruitment Team Alignment]@row = "H&E", 1300), IF([Recruitment Team Alignment]@row = "ID&A", 1400), IF([Recruitment Team Alignment]@row = "Global HQ", 1500), IF([Recruitment Team Alignment]@row = "People Movement", 1600), IF([Recruitment Team Alignment]@row = "Strategy & Operations", 1700), IF([Recruitment Team Alignment]@row = "Transitions", 1800))


I've also tried..


=IF([Recruitment Team Alignment]@row = "AMS Central", 100, [Recruitment Team Alignment]@row = "AMS Sales", 200, [Recruitment Team Alignment]@row = "AMS Corporate Functions", 300, [Recruitment Team Alignment]@row = "AMS ONEx", 400, [Recruitment Team Alignment]@row = "AMS Engineering1", 500, [Recruitment Team Alignment]@row = "AMS Engineering2", 600, [Recruitment Team Alignment]@row = "AMS Engineering3", 700, [Recruitment Team Alignment]@row = "AMS Director Plus", 800, [Recruitment Team Alignment]@row = "AMS Sourcing", 900, [Recruitment Team Alignment]@row = "APJC", 1000, [Recruitment Team Alignment]@row = "EMEA", 1100, [Recruitment Team Alignment]@row = "ETR", 1200, [Recruitment Team Alignment]@row = "H&E", 1300, [Recruitment Team Alignment]@row = "ID&A", 1400, [Recruitment Team Alignment]@row = "Global HQ", 1500, [Recruitment Team Alignment]@row = "People Movement", 1600, [Recruitment Team Alignment]@row = "Strategy & Operations", 1700, [Recruitment Team Alignment]@row = "Transitions", 1800)

Best Answer

  • Andrée Starå
    Andrée Starå ✭✭✭✭✭✭
    edited 09/27/22 Answer ✓

    Hi @mtetzlaf

    I hope you're well and safe!

    Try something like this.

    =

    IF([Recruitment Team Alignment]@row = "AMS Central", 100, 

    IF([Recruitment Team Alignment]@row = "AMS Sales", 200, 

    IF([Recruitment Team Alignment]@row = "AMS Corporate Functions", 300, 

    IF([Recruitment Team Alignment]@row = "AMS ONEx", 400, 

    IF([Recruitment Team Alignment]@row = "AMS Engineering1", 500, 

    IF([Recruitment Team Alignment]@row = "AMS Engineering2", 600, 

    IF([Recruitment Team Alignment]@row = "AMS Engineering3", 700, 

    IF([Recruitment Team Alignment]@row = "AMS Director Plus", 800, 

    IF([Recruitment Team Alignment]@row = "AMS Sourcing", 900, 

    IF([Recruitment Team Alignment]@row = "APJC", 1000, 

    IF([Recruitment Team Alignment]@row = "EMEA", 1100, 

    IF([Recruitment Team Alignment]@row = "ETR", 1200, 

    IF([Recruitment Team Alignment]@row = "H&E", 1300, 

    IF([Recruitment Team Alignment]@row = "ID&A", 1400, 

    IF([Recruitment Team Alignment]@row = "Global HQ", 1500, 

    IF([Recruitment Team Alignment]@row = "People Movement", 1600, 

    IF([Recruitment Team Alignment]@row = "Strategy & Operations", 1700, 

    IF([Recruitment Team Alignment]@row = "Transitions", 1800)

    Did that work/help?

    I hope that helps!

    Be safe, and have a fantastic week!

    Best,

    Andrée Starå | Workflow Consultant / CEO @ WORK BOLD

    Did my post(s) help or answer your question or solve your problem? Please support the Community by marking it Insightful/Vote Up, Awesome, or/and as the accepted answer. It will make it easier for others to find a solution or help to answer!

    SMARTSHEET EXPERT CONSULTANT & PARTNER

    Andrée Starå | Workflow Consultant / CEO @ WORK BOLD

    W: www.workbold.com | E:andree@workbold.com | P: +46 (0) - 72 - 510 99 35

    Feel free to contact me for help with Smartsheet, integrations, general workflow advice, or anything else.

Answers

  • Andrée Starå
    Andrée Starå ✭✭✭✭✭✭
    edited 09/27/22 Answer ✓

    Hi @mtetzlaf

    I hope you're well and safe!

    Try something like this.

    =

    IF([Recruitment Team Alignment]@row = "AMS Central", 100, 

    IF([Recruitment Team Alignment]@row = "AMS Sales", 200, 

    IF([Recruitment Team Alignment]@row = "AMS Corporate Functions", 300, 

    IF([Recruitment Team Alignment]@row = "AMS ONEx", 400, 

    IF([Recruitment Team Alignment]@row = "AMS Engineering1", 500, 

    IF([Recruitment Team Alignment]@row = "AMS Engineering2", 600, 

    IF([Recruitment Team Alignment]@row = "AMS Engineering3", 700, 

    IF([Recruitment Team Alignment]@row = "AMS Director Plus", 800, 

    IF([Recruitment Team Alignment]@row = "AMS Sourcing", 900, 

    IF([Recruitment Team Alignment]@row = "APJC", 1000, 

    IF([Recruitment Team Alignment]@row = "EMEA", 1100, 

    IF([Recruitment Team Alignment]@row = "ETR", 1200, 

    IF([Recruitment Team Alignment]@row = "H&E", 1300, 

    IF([Recruitment Team Alignment]@row = "ID&A", 1400, 

    IF([Recruitment Team Alignment]@row = "Global HQ", 1500, 

    IF([Recruitment Team Alignment]@row = "People Movement", 1600, 

    IF([Recruitment Team Alignment]@row = "Strategy & Operations", 1700, 

    IF([Recruitment Team Alignment]@row = "Transitions", 1800)

    Did that work/help?

    I hope that helps!

    Be safe, and have a fantastic week!

    Best,

    Andrée Starå | Workflow Consultant / CEO @ WORK BOLD

    Did my post(s) help or answer your question or solve your problem? Please support the Community by marking it Insightful/Vote Up, Awesome, or/and as the accepted answer. It will make it easier for others to find a solution or help to answer!

    SMARTSHEET EXPERT CONSULTANT & PARTNER

    Andrée Starå | Workflow Consultant / CEO @ WORK BOLD

    W: www.workbold.com | E:andree@workbold.com | P: +46 (0) - 72 - 510 99 35

    Feel free to contact me for help with Smartsheet, integrations, general workflow advice, or anything else.

  • This worked!

    Thanks so much!

  • Andrée Starå
    Andrée Starå ✭✭✭✭✭✭

    @mtetzlaf

    Excellent!

    Happy to help!

    One issue was that you closed out the IF parts, so it didn't continue checking the others.

    Remember! Did my post(s) help or answer your question or solve your problem? Please support the Community by marking it Insightful/Vote Up/Awesome or/and as the accepted answer. It will make it easier for others to find a solution or help to answer!

    SMARTSHEET EXPERT CONSULTANT & PARTNER

    Andrée Starå | Workflow Consultant / CEO @ WORK BOLD

    W: www.workbold.com | E:andree@workbold.com | P: +46 (0) - 72 - 510 99 35

    Feel free to contact me for help with Smartsheet, integrations, general workflow advice, or anything else.

Help Article Resources

Want to practice working with formulas directly in Smartsheet?

Check out the Formula Handbook template!