Re: java.util.Date & StoredProcedure

From: Cris Daniluk (cris.danilu..mail.com)
Date: Tue Feb 28 2006 - 13:54:34 EST


j.u.Date includes the time part, so you shouldn't be having trouble. I
can confirm that you can return the time part from an oracle stored
proc, at least in my environment.

Are you sure your stored proc / cursor isn't truncating the date via
implicit casting, etc? Also, in addition to the ObjEntity, there is
also the actual stored procedure entry in the modeler. Make sure you
are specifying the appropriate JDBC type there.

Cris

On 2/28/06, Pirola Davide <davide.pirol..tin.it> wrote:
> Hi Andrus,
> i have a problem with a Date returned form a Oracle cursor in a Stored Procedure.
> I correctly access to data in the cursor, but when i get the value of a Date field, this value haven't the hour/minute/second... only day/month/year.
> I have modified the obj-entity (datamap.xml) in order to map my date field to a java.sql.Timestamp, but cayenne still return me a java.util.Date.
> You can confirm me that also with Stored procedure the type written in the obj-idenity is the one that is returned... or there is a different policy in this case?
>
> Thank's
> Davide
>



This archive was generated by hypermail 2.0.0 : Tue Feb 28 2006 - 13:54:36 EST