db-derby-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Max Ten" <max.te...@gmail.com>
Subject Best way to define Timestamp column?
Date Thu, 23 Feb 2006 19:19:25 GMT
CREATE TABLE t (
  ts1 TIMESTAMP ,
  ts2 TIMESTAMP NOT NULL DEFAULT '0000-00-00 00:00:00'
);

INSERT INTO T (TS2) VALUES ('0001-01-01-00.00.00.000000');


If execute the insert statement, ts1 column can be blank, but ts2 must have
a valid datetime value.
So by using getTimestamp in java to retrieve from Derby,  what is the pro
and cons when creating timestamp column as above?

thank you.

Mime
View raw message