If the date of 1900-01-01 00:00:00.000 is considered Null in Outsystems, how can I represent it as someone's birthday? I could change the hour, day or second, but that seems like a band-aid solution. Is this a huge oversight in the Outsystemscloud design? Why would the 1st of January 1900 be considered null?
Hi @Gordon Ramsay
Check this thread, I think that as the explanation regarding null values: https://www.outsystems.com/forums/discussion/33882/null-value-decimal/#Post184472
Regards
Gonçalo Almeida
Hi Gordon,
I am leaving the discussion to why OutSystems to decide to have a null date as 1900-01-01.
To answer your question, how can you represent a date actually being on 1900-01-01?
You could, as a workaround, for example introduce an extra boolean attribute in your data model, that will tell you that 1900-01-01 for that record actually represents an actual date.
Regards,
Daniel
Nobody who's alive has a birthday of 1-1-1900, so unless you are making a database of historical data, you'll be fine. Choosing some date to mean "no date" is a practice that's decades old, and chosing 1-1-1900 allows all databases to safely store the date (when OutSystems was designed, 15 years ago, other possible candidates like 1-1-0000 weren't available for that reason).
That said, if you really need a specific date field to contain a valid value of 1-1-1900, there's nothing stopping you to do that. Other than 1-1-1900 being equal to NullDate(), it works fine in all built-in date/time handling Actions and Functions like AddDays etc., you can display it, and so on. You just pick another date that indicates "unknown" or the like (1-1-3000 or something), and remember to not use NullDate() to test against that specific attribute.