Default value on Date column

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • Q. John Chen

    #1

    Default value on Date column

    Using MySQL control center, I created a MySQL database table with a
    column of Date type. It always give the a Default value (0000-00-00)
    even null is allowed. I tried remove the default value and it comes
    back by itself.

    So if I don't supply a value when insert, the default is used. Query
    IS NOT NULL will not exclude this record.

    Now, In VB (with ADO/MyOLEDB), I did the exact query trying to filter
    out the null record. But I still get the record just like in Control
    Center. BUT, the value on this column is "NULL".

    How can I leave the Date field as null if no value is supplied?
Working...