Workdate Formula Error

  • 0
  • 1
  • Question
  • Updated 1 year ago
  • Answered
This formula, which is defining a formula workdate field, works fine, unless the end result is to pull  from a workdate field: 

If  ((Trim([Predecessors])="") and (IsNull([Start])), [Date Created],
[Start]
)

  If I replace the last "[Start]", which is a workdate, with "[Date Created]", then the formula works.  As is, though, I get a formula error for bad or missing function call. Is this a bug, or am I missing something?
Photo of Yehudah Greenberg

Yehudah Greenberg

  • 600 Points 500 badge 2x thumb

Posted 1 year ago

  • 0
  • 1
Photo of QuickBaseCoach App Dev./Training

QuickBaseCoach App Dev./Training, Champion

  • 53,702 Points 50k badge 2x thumb
Date Created is a date time/field type.  A work date does not have the concept of the time of day.

Do you want your result to be a date or a date/time or a workdate?
Photo of Yehudah Greenberg

Yehudah Greenberg

  • 600 Points 500 badge 2x thumb
That's what is confusing me.  Date Created works fine in this formula, it's "start" that is giving me trouble.  For example, if I would get rid of the last line, it displays date created without a hitch.  (And it would functions a workdate is regards to predecessors.)
The truth is that I WOULD like the best of both worlds- Date created (not a workdate) if no other date is defined, but otherwise, a workdate.
Photo of Yehudah Greenberg

Yehudah Greenberg

  • 600 Points 500 badge 2x thumb
Sorry for the gibberish in the parentheses.  Read:  It would function as a workdate in regards to predecessors.  
Photo of QuickBaseCoach App Dev./Training

QuickBaseCoach App Dev./Training, Champion

  • 53,702 Points 50k badge 2x thumb
What happens if you convert the [date created] field to a date result with ToDate([Date Created])
Photo of Yehudah Greenberg

Yehudah Greenberg

  • 600 Points 500 badge 2x thumb
If I do that and leave everything as is, I get the same error.
Photo of Yehudah Greenberg

Yehudah Greenberg

  • 600 Points 500 badge 2x thumb
Mark, your comment spurred me to find a workaround.  I created another formula workdate field    "[Convert Date Created]"  with the formula ToDate([Date Created]), and then used this field instead of [Date Created].  I still don't understand the logic of the error, though.
Photo of QuickBaseCoach App Dev./Training

QuickBaseCoach App Dev./Training, Champion

  • 53,702 Points 50k badge 2x thumb
OK,Thx for letting me know it is working now.