Help creating a formula

Can someone help me fix the following formula?

# of Travel Trips = IF(([Onsite Delivery]@row = "Onsite" , [Software Installation Hours]@row >40, 1, or <41-79, 2, or <80, 3) * [Number of Sites]@row))

Not sure what to do with the ORs...or how to include them all into the formula. Do I have too many parenthesis?


Best Answers

  • Heather Duff
    Heather Duff ✭✭✭✭✭✭
    edited 04/12/21 Answer ✓

    @Stacy Stoffel , try removing the 2 end parenthesis at the end of the formula. That should do the trick.

  • Heather Duff
    Heather Duff ✭✭✭✭✭✭
    Answer ✓

    Oh! I'm so sorry - let's try this again:

    =if([onsite delivery]@row<>"Onsite",0,if(AND([Onsite Delivery]@row = "Onsite",[Software Installation Hours]@row <=40),1,if(AND([Onsite Delivery]@row = "Onsite",[Software Installation Hours]@row <=79,2,if(AND([Onsite Delivery]@row = "Onsite",[Software Installation Hours]@row >80,3,""))))*[Number of Sites]@row

    I just changed the "=0" to '<>"Onsite"'. It means if Onsite Delivery does not equal Onsite, display 0.

    Let me know if that fixes it.


Help Article Resources

Want to practice working with formulas directly in Smartsheet?

Check out the Formula Handbook template!