Re: How to get generated keys without requerying the database?

2011-01-25 Thread robsinner
Jeremy (and Kevin), Thank you so much for your quick turnaround time and response and the workaround. I modified the persistence.xml with I also created a bug in JIRA- My first one so I hope that it was detailed enough. https://issues.apache.org/jira/browse/OPENJPA-1930 Thanks again, it is

Re: How to get generated keys without requerying the database?

2011-01-25 Thread robsinner
DB2 (from Control Center Help About) Product Identifier SQL09072 Level Identifier 08030107 Level DB2 v9.7.200.358 Build Level s100514 PTF IP23084 JCC Driver is db2jcc4-9.7.100.177.jar, db2jcc_license_cu-9.7.100.177.jar Thank you for your help, R S -- View this message in context: http://open

Re: How to get generated keys without requerying the database?

2011-01-25 Thread robsinner
DB2 (from Control Center Help About) Product Identifier SQL09072 Level Identifier 08030107 Level DB2 v9.7.200.358 Build Level s100514 PTF IP23084 JCC Driver is db2jcc4-9.7.100.177.jar, db2jcc_license_cu-9.7.100.177.jar Thank you for your help, R S -- View this message in context: http://openj

Re: How to get generated keys without requerying the database?

2011-01-25 Thread robsinner
Kevin, Thanks for your response. I am including the full log from my junit test with TRACE turned on via openjpa.Log in persistence.xml I am using the DB2Dictionary in my persistence.xml I have a junit test which prints out these two variables from the DB2Dictionary. public void t

Re: How to get generated keys without requerying the database?

2011-01-25 Thread robsinner
Thanks so much for your quick response. I really appreciate it. I tried adding the em.flush after the em.persist and I am still getting the same behavior i.e. After the insert the dto.recId which is mapped to an non primary key IDENTITY column is not populated on the DTO although the REC_ID exi

How to get generated keys without requerying the database?

2011-01-24 Thread robsinner
I have an Entity with a non primary key identity column. This entity Part.java has the following fields among others @EmbeddedId private PartPK pk; @GeneratedValue(strategy=GenerationType.IDENTITY) @Column(name="REC_ID") private Integer recId; Note t