You are viewing a plain text version of this content. The canonical link for it is here.
Posted to torque-user@db.apache.org by Axel Seinsche <ax...@seinsche.net> on 2004/04/26 08:44:31 UTC

saving time part of date with Oracle 9i

Hi all,

I know this has been discussed on this list before. As I can not solve this problem I thought it's easier to ask here again. ;-)

I want to store date AND time value in my Oracle DB using Torque. The DB datatype DATE from Oracle allows this. But my application still saves just the date part. Time is alway 00:00:00. I tried to use java.sql.Timestamp instead of java.util.Date, but it doesn't change anything. Even using Oracle's new type TIMESTAMP didn't bring the expected effect.

When I had a look at the Torque source code, I saw in the DBOracle class that the function for inserting dates should work correctly. Still the question remains, how do I store the time part of my date? 

Notice: I am using Oracle 9i Rel. 2 with ojdbc14.jar and Torque 3.1

Regards,
Axel