-
1. Re: Oracle and java.sql.Date
h2o_polo Jan 28, 2003 5:33 PM (in response to rafonso)I do not think java.sql.Date stores the time.
Make jbuilder generate either java.util.Date, or java.sql.Timestamp (I think) -
2. Re: Oracle and java.sql.Date
rafonso Jan 29, 2003 3:12 PM (in response to rafonso)According java.sql.date definition (see http://java.sun.com/j2se/1.3/docs/api/java/sql/Date.html): "To conform with the definition of SQL DATE, the millisecond values wrapped by a java.sql.Date instance must be 'normalized' by setting the hours, minutes, seconds, and milliseconds to zero in the particular time zone with which the instance is associated.". So hours were zeroed by java.sql.Date itself.
I changed attribute type from java.sql.Date to java.sql.Timestamp (see http://java.sun.com/j2se/1.3/docs/api/java/sql/Timestamp.html). Now hours are regisred correctly. Actually, according
Thanks,
Rafael U. C. Afonso -
3. Re: Oracle and java.sql.Date
rafonso Jan 29, 2003 3:15 PM (in response to rafonso)h2o_polo:
You are right. I changed my attribute type to java.sql.Timestamp and now hours are registered.
Thanks,
Rafael U. C. Afonso