Help

Upcoming database upgrades. Airtable functionality will be reduced for ~15 minutes at 06:00 UTC on Feb. 4 / 10:00 pm PT on Feb. 3. Learn more here

If Blank than Blank

Topic Labels: Formulas
Solved
Jump to Solution
836 2
cancel
Showing results for 
Search instead for 
Did you mean: 

Hey Guys,
Trying to figure out how to leave a cell BLANK.
I’m tracking soccer games.

Here’s my formula:

IF({Home Score} > {Away Score}, {Home Team} & " " & “Wins!!”,IF({Away Score}>{Home Score},{Away Team} & " " & “Wins!”,IF({Home Score}={Away Score},“Draw”)))

The first part is ok. I get the right values for HOME / AWAY & DRAW. the problem is with future games, where the “score” cells are still empty, I get “Draw”. technically it’s true, but I’d like to leave the cell empty or insert a placeholder text instead.

Thanks in advance.

1 Solution

Accepted Solutions

You’ll want to first check if both scores are empty (or alternatively, if both scores are entered), then run the rest of your formula.

IF(AND({Home Score}, {Away Score}), IF({Home Score} > {Away Score}, {Home Team} & " Wins!", IF({Away Score} > {Home Score}, {Away Team} & " Wins!", IF({Home Score} = {Away Score}, "Draw"))))

You can also simplify your formula a little like so:
IF(AND({Home Score, {Away Score}), IF({Home Score} = {Away Score}, "Draw", IF({Home Score} > {Away Score}, {Home Team}, {Away Team}) & " Wins!"))

See Solution in Thread

2 Replies 2

You’ll want to first check if both scores are empty (or alternatively, if both scores are entered), then run the rest of your formula.

IF(AND({Home Score}, {Away Score}), IF({Home Score} > {Away Score}, {Home Team} & " Wins!", IF({Away Score} > {Home Score}, {Away Team} & " Wins!", IF({Home Score} = {Away Score}, "Draw"))))

You can also simplify your formula a little like so:
IF(AND({Home Score, {Away Score}), IF({Home Score} = {Away Score}, "Draw", IF({Home Score} > {Away Score}, {Home Team}, {Away Team}) & " Wins!"))

Thanks kamille! I really appreciate it.