Skip to main content
Solved

Formula to Correct #ERROR! for Empty Date Field

  • July 17, 2024
  • 2 replies
  • 24 views

Forum|alt.badge.img+9

Hello Airtable Community,

My table includes an event title field as well as one for an event date.

Event Title:
The Chemical Regulations Landscape

Event Date:
June 6, 2004

Formula:
LEFT({Event Title}, 16)&" - "&{Date}

Formula Result:
The Chemical Reg - 6/6/2024

All good so far…but there are also records that have an event title and no event date, so the formula above  returns #ERROR! for these records.

So, for the records sans event date, how can I modify the formula so that it returns the first 16 characters of the event name instead of generating an error?

Many thanks in advance for your assistance!

John

Best answer by Sistema_Aotearo

Hiya! Try this formula and let me know if it works for you!

LEFT({Event Title}, 16) &
IF(NOT(
   {Date}=""),
   " - " & DATETIME_FORMAT({Date}, "DD-MM-YYYY")
)

2 replies

Sistema_Aotearo
Forum|alt.badge.img+20

Hiya! Try this formula and let me know if it works for you!

LEFT({Event Title}, 16) &
IF(NOT(
   {Date}=""),
   " - " & DATETIME_FORMAT({Date}, "DD-MM-YYYY")
)

Forum|alt.badge.img+9
  • Author
  • Known Participant
  • July 18, 2024

Hiya! Try this formula and let me know if it works for you!

LEFT({Event Title}, 16) &
IF(NOT(
   {Date}=""),
   " - " & DATETIME_FORMAT({Date}, "DD-MM-YYYY")
)

👍Thank you very much! Greatly appreciated!