Skip to content

Instantly share code, notes, and snippets.

Excel tips and tricks

A place to store formulas and other handy things from Excel

How to fill a column with values based on conditions in another column

This checks the cell B2 to verify if it is higher than zero to assign a value of Happy. If not it checks if it is negative to assign a value of Sad or Neutral if B2 is zero.

=IF(B2>0;"Happy";IF(B2<0;"Sad";"Neutral"))