Thanks for reply .
but I can not change the org.exolab.castor.types.Date
in my generated object ( generated using
SourceGenerator utility which converts XML Schema to
object) .
I heard that we can write the handler to handle that
date . Any idea how to do that ?
Also let me know mapping between possible DB2 Sql and
Java types.
Regards
Suhas
--- Robin Hoogeboom <[EMAIL PROTECTED]> wrote:
> Hi,
>
>
> We ran into the same problem. We fixed it changing
> type Date into
> DateTime. This type is generated as java.util.Date
> which is jdbc driver
> compliant.
>
> Read/write to database is no problem (you don't need
> the timestamp),
> only if your using a xml marshal/unmarshal you need
> an timestamp.
>
>
> Hope it helps,
>
> Robin Hoogeboom
>
> p.s. in your mapping file you can use "date" as type
> (no org.exolab.etc)
>
> ----- Origineel Bericht -----
> Van: Suhas Kulkarni <[EMAIL PROTECTED]>
> Datum: Dinsdag, Oktober 29, 2002 4:24 pm
> Onderwerp: [castor-dev] Problem in JDO mapping
>
> > Hi ,
> > I have one question while working with Castor JDO.
> > I create the object from XML Schema using
> > SourceGenerator utility and then I persist those
> > object to DB2 database using JDO O/R mapping .
> >
> > Now when I convert the xml schema to object,
> > properties of object containing dates gets type as
> > org.exolab.castor.types.Date
> > like -
> > class PolicyDO {
> > public org.exolab.castor.types.Date _creationDate;
> > // Setters and getters for _creationDate property
> ;
> > }
> >
> > Now I want to persist this object using JDO O/R
> > mapping . so I specify mapping file containing -
> > ...
> > <field name="creationDate"
> > type="org.exolab.castor.types.Date">
> > <sql name="createdateCol" type="date" />
> > </field>
> > ...
> >
> > This is where I'm getting problem as Castor Date
> of
> > 'CreationDate' do not match with date type of
> Database
> > Column , I'm not able to get the instance of JDO .
> >
> > How to solve this ??
> >
> > Regards
> > Suhas
> >
> >
> >
> > __________________________________________________
> > Do you Yahoo!?
> > HotJobs - Search new jobs daily now
> > http://hotjobs.yahoo.com/
> >
> >
>
-----------------------------------------------------------
>
> > If you wish to unsubscribe from this mailing, send
> mail to
> > [EMAIL PROTECTED] with a subject of:
> > unsubscribe castor-dev
> >
> >
>
>
-----------------------------------------------------------
>
> If you wish to unsubscribe from this mailing, send
> mail to
> [EMAIL PROTECTED] with a subject of:
> unsubscribe castor-dev
>
__________________________________________________
Do you Yahoo!?
HotJobs - Search new jobs daily now
http://hotjobs.yahoo.com/
-----------------------------------------------------------
If you wish to unsubscribe from this mailing, send mail to
[EMAIL PROTECTED] with a subject of:
unsubscribe castor-dev