Author Topic: DateTime null value  (Read 2811 times)


  • New Member
  • *
  • Posts: 31
Re: DateTime null value
« Reply #15 on: April 02, 2019, 06:58:25 pm »
There is some strange behaviour with regard to dates in the range 1/1/0001 to 30/1/0001. If a date in this range or a null value is entered then a DBGrid will show a blank cell, also
Code: Pascal  [Select][+][-]
  1. WineDBF.FieldByName('Date').AsString
returns a null string, whereas
Code: Pascal  [Select][+][-]
  1. datetostr(WineDBF.FieldByName('Date').AsDateTime
returns a string of a date, 30/12/1899.

Dates from 31/1/0001 seem to be handled correctly.

Any thoughts.


TinyPortal © 2005-2018