Google-sheets – How to use TODAY() as part of a formula checking against a list of dates in Google Sheets

formulasgoogle sheetsgoogle-sheets-dates

I'm trying to use the TODAY() formula to check against a long column of date cells, and mark them as 'LIVE' if the given date is less than (or equal to) today. Crucially though, if the date cell is greater than today, or left blank, it should be marked as 'NO' (or just left blank).

So I guess I'm trying to say:

If A1 = less than or equal to today then 'LIVE', if not or blank then 'NO'.

I've tried using =A1<TODAY() and this works, except if A1 is blank in which case it still marks it as TRUE.

Can anyone help? I'm very much a beginner with formula and I can't seem to find the right way to do it.

Best Answer

Dates are basically numbers and Google identifies blanks as 0 when comparing to numbers, thus you have to add check for blanks.

=ARRAYFORMULA(IF(A:A="","NO",IF(A:A<=TODAY(),"LIVE","NO")))