>>Hi,
>>I'm currently trying to read a table from an MySQL database that has a
[quoted text clipped - 12 lines]
> Although I can imagine some reasons why you might want this you simply
> should not do this with a Date column in a relational database.
Silvio,
It's legacy (and explaining why would be a long rambling explanation of
what you can/can't do when you don't have transactions, which honestly
for some applications is just fine).
> I suspect there will be few other DBMS systems that will let you get away
> with this.
MySQL won't let you do it either if you start it with the
"NO_ZERO_IN_DATE" sql mode.
The JDBC driver itself will not create such dates, nor will it read them
by default, since Java has no way to represent a non-sensical date. It
sounds more like the other poster has a data model problem from the
start, in that he's using sentinel values to represent the concept of NULL.
-Mark
Silvio Bierman - 22 Dec 2005 23:01 GMT
Hello Mark,
Legacy would be the only reason why such behaviour could exist. I would
prefer the default behaviour to be different though, one of the values of
using a RDBMS is the integrity checking at the data storage level.
Regards,
Silvio Bierman