Posted By:
Amir_Pashazadeh
Posted On:
Friday, December 27, 2002 04:21 AM
Hi all, I'm developing an application using Oracle 9i and Weblogic 6.1 as EJB Container, I'm using 2 CMP 2 Entity Beans, their tables are related on database, but I have not used CMR relation, (relation is one to many in database) Suppose table names (and Entity EJB names) are A and B, and A has a one to may relationship with B, A's primary key is a composite key (more than one column) and it contains a DATE column in its primary key, wich is mapped to a Timestamp field in ABean , I find an Entity EJB from A using a finder, then I get its primary key and try to create a BBean , but the time I get from A and the time I put in B are not the same if my Timezo
More>>
Hi all,
I'm developing an application using
Oracle 9i
and
Weblogic 6.1
as EJB Container, I'm using 2 CMP 2 Entity Beans, their tables are related on database, but I have not used CMR relation, (relation is one to many in database)
Suppose table names (and Entity EJB names) are A and B, and A has a one to may relationship with B,
A's primary key is a
composite key
(more than one column) and it contains a
DATE
column in its primary key, wich is mapped to a Timestamp field in
ABean
,
I find an Entity EJB from A using a finder, then I get its primary key and try to create a
BBean
, but the time I get from A and the time I put in B are not the same
if my Timezone is not Greenwich!
and I get a Foriegn Key Error from Oracle, but when I change the Timezone to Greenwich there are no errors more,
I don't make any process on the Timestamp field just read it from
ABean
and Store it on
BBean
using
BHome.create()
,
can anyone help me why this problem happens, and how can I fix it?
thanx,
Amir
<<Less