Forum Discussion

JenniferJennif2's avatar
JenniferJennif2
Qrew Member
9 years ago

How do I create a formula field to display one of two date fields, depending on which one is not empty?

I have two date fields. One is required [Date A], but the other is optional [Date B]. How do I create a formula field to default to display optional [Date B] unless [Date B] is empty, then display [Date A]? Thank you!

13 Replies

  • no problem

    The formula for a formula date field would be

    IF(not IsNull([Date B]),[Date B],[Date A])
    • AmberPollard's avatar
      AmberPollard
      Qrew Assistant Captain
      Hmm, I used this formula exactly and I'm getting the error: Formula error -- Bad or missing arguments in function call

      • If(not IsNull([Date]),[Date],[Date Modified])
      My field type is a formula Date field. Should I be using another field type?

      Thanks!
    • QuickBaseCoachD's avatar
      QuickBaseCoachD
      Qrew Captain
      • If(not IsNull([Date]),[Date],ToDate([Date Modified]))
      The field [date modified] is actually a date/time field, not a date field.  So it needs to be converted to be a date type.