# Multiple IFS for calculations

Options
edited 12/09/19

Hi,

I have no problem doing this in Google Sheets but I'm not sure how to do this in Smartsheet.

I have columns that contain THC and CBD content, measured in a number of different ways, including percentages, mg, percentage ranges, etc., but they're always consistent units of measurement across the row.

I need to calculate the following:

THC>CBD = THC

CBD>THC=CBD

Equal THC/CBD=THC

Blank=Leave blank

I'm not able to get all of these IF statements to work together, I get a number of errors depending on how I structure the formula.

Any suggestions?

Thank you,

Tags:

• ✭✭✭✭✭✭
Options

Hi Rachel,

Can you describe your process in more detail and maybe share the sheet(s) or some screenshots? (Delete/replace any confidential/sensitive information before sharing) That would make it easier to help. (share too, andree@getdone.se)

Have a fantastic week!

Best,

Andrée Starå

Workflow Consultant @ Get Done Consulting

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.

• Options

Hi Andree,

Please see the attached image for an explanation. We currently are exporting into Google Sheets to do this calculation and re-importing the data.

Thank you!

• Options

Hello,

Below is a basic statement based upon the information provided.  Hopefully this will help you get started. Copy code below into top Cell "Active Cannabinoid" column and drag down results to remaining cells in column.

=IF(ISBLANK(\$[THC Per Unit]@row), "", IF(ISBLANK(\$[CBD Per Unit]@row), "", IF(\$[THC Per Unit]@row > \$[CBD Per Unit]@row, "THC", IF(\$[CBD Per Unit]@row > \$[THC Per Unit]@row, "CBD", IF(\$[CBD Per Unit]@row = \$[THC Per Unit]@row, "THC")))

Regards,

Dave

• ✭✭✭✭✭✭
Options

Happy to help!

Let me know if I can help with anything else!

Best,

Andrée

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.

• Options

Wow Dave this is awesome! Thank you so much

• ✭✭✭✭✭✭
Options

The only issue I could see arising from this though is that the numbers are being stored as a text string. You may need to pull the numbers and convert them from text values to numerical values before you can get an accurate comparison.

## Help Article Resources

Want to practice working with formulas directly in Smartsheet?

Check out the Formula Handbook template!