Regarding automatic type conversion of joincolumns

2009-02-23 Thread RamAESIS
Hi, I have a requirement as mentioned below: Table A has a column COL1 of type VARCHAR2, table B has column COL2 of type NUMBER. When i provide the COL2 as join column for the @OneToMany annotations OpenJPA is throwing an exception for type mismatch. Is there any work around or solution to type

Re: How to get beter stacktraces????

2009-02-23 Thread kurt_cobain
I tried the persistence.xml entry, didn't help... I'm just not sure how to develop in the dark like this with no useful error message... this isn't the first time I've gotten that generic error either. This is just terrible. -- View this message in context: http://n2.nabble.com/How-to-get-beter

Re: How to get beter stacktraces????

2009-02-23 Thread Craig L Russell
I've see in these cases that it's hard to get the details of what went wrong since the error is being reported to you at commit time while the error actually occurred earlier. Getting the earlier stack trace is what is needed, and this requires some coordination between WebLogic and OpenJPA

Re: How to get beter stacktraces????

2009-02-23 Thread Pinaki Poddar
Hi, The stack trace posted here points to no OpenJPAException. A OpenJPAException often carry the nested throwables. But in a long JEE stack who knows who is swallowing whose exceptions? Going by the javadoc of the application-visible weblogic.transaction.RollbackException, there are two met

Re: How to get beter stacktraces????

2009-02-23 Thread Michael Dick
Hi, I've never used WebLogic, so I can't help with specifics. I'd guess that there was a nested SQLException. Turning on OpenJPA SQL trace might help. In JSE you can do this by adding a property to persistence.xml : WebLogic may have other ways to enable OpenJPA's SQL trace (quick googling didn'

Re: How to get beter stacktraces????

2009-02-23 Thread kurt_cobain
Yeah I saw those; but in tracing down into the code, I can see that an exception actually never gets thrown. What I get is an exception from weblogic like this: Feb 23, 2009 5:00:01 PM CST> org.apache.openjpa.util.StoreException: The transaction has been rolled back. See the nested exception

Re: How to get beter stacktraces????

2009-02-23 Thread Timothy C. Fanelli
The OpenJPA StoreException class has a "type" property that may provide you additional information. Make sure also that you're printing out the stack trace of the nested exception. Check out the JavaDoc for the exception class: http://openjpa.apache.org/builds/1.2.0/apache-openjpa-1.2.0/docs/javad

Re: How to get beter stacktraces????

2009-02-23 Thread kurt_cobain
The problem is that it isn't telling me "why" the transaction has been rolled back; for example the way you do if you try and insert a null value into a non-nullable column etc, you typically get a jdbc error. I'm getting zero... From: Pid (via Nabble) To: k

Re: How to get beter stacktraces????

2009-02-23 Thread kurt_cobain
Obviously, I've done that; it's on a single line of code, the persist method of the entity manager. The object graph looks good as far as I can tell. From: Pid (via Nabble) To: kurt_cobain Sent: Monday, February 23, 2009 5:23:40 PM Subject: Re: How to get be

Re: How to get beter stacktraces????

2009-02-23 Thread Pid
Pid wrote: > kurt_cobain wrote: >> I'm having a very difficult time with OpenJPA (via weblogic). >> >> I often get a strack trace that doesn't help me at all, it just looks like >> this: >> >> "org.apache.openjpa.util.StoreException: The transaction has been rolled >> back. See the nested exceptio

Re: How to get beter stacktraces????

2009-02-23 Thread Pid
kurt_cobain wrote: > I'm having a very difficult time with OpenJPA (via weblogic). > > I often get a strack trace that doesn't help me at all, it just looks like > this: > > "org.apache.openjpa.util.StoreException: The transaction has been rolled > back. See the nested exceptions for details on

How to get beter stacktraces????

2009-02-23 Thread kurt_cobain
I'm having a very difficult time with OpenJPA (via weblogic). I often get a strack trace that doesn't help me at all, it just looks like this: "org.apache.openjpa.util.StoreException: The transaction has been rolled back. See the nested exceptions for details on the errors that occurred." And

"No field named"-problem when using subclass field in where-clause

2009-02-23 Thread Joakim Olsson
Hi all, I have a problem when trying to find objects of a base-class by using a field from one of the subclasses in the where-clause. The error I get is a 'No field named "xxx" in class "yyy"'. Hibernate resolves this kind of query but OpenJPA obviously does not. Example: Base-class: import jav

Re: [vote] release openjpa-maven-plugin 1.0-SNAPSHOT

2009-02-23 Thread Pinaki Poddar
Hi, Excellent! Do I have a vote? (In most places, I don't). If I do, then +1. Mark Struberg wrote: > > Hi! > > We are proud to call a vote for releasing a new version of the > openjpa-maven-plugin! > > The following features have been added since the last release: > > o added mojo open

Re: @Id, @TableGenerator - Id creation fails when using a connection pool (inside Geronimo 2.1.3)

2009-02-23 Thread Pinaki Poddar
Hi, "When using a managed DataSource, you should also configure a second unmanaged DataSource that OpenJPA can use to perform tasks that are independent of the global transaction. The most common of these tasks is updating the sequence table OpenJPA uses to generate unique primary key values for

Re: Removing entity with Embedded field

2009-02-23 Thread Pinaki Poddar
I had put a fix for this issue recently OPENJPA-935. Will the original reporter please verify? OpenJPA makes a decision during bulk delete whether the delete operation involves a single table only. That decision was not accounting for cascade behavior for embedded fields. [1] http://issues.apa

Re: Eclipse Plugin for OpenJPA

2009-02-23 Thread Pinaki Poddar
Yup, I agree. Did this separate subproject require approval from Apache Board? Donald Woods wrote: > > For Geronimo, we also setup a Devtools subproject for our Eclipse > plugins. I would suggest doing that for OpenJPA, as the maven builds > are different enough that you don't want non-Eclip

Re: Eclipse Plugin for OpenJPA

2009-02-23 Thread Pinaki Poddar
Hi, > I've noticed that OpenEJB has a separate project for the OpenEJB Eclipse > Plugin. > Maybe we should consider following the same path? If you are saying we should make this stuff part of openjpa officially (meaning some new openjpa-eclipse module) then I have some concerns. I am not con

Re: Eclipse Plugin for OpenJPA

2009-02-23 Thread Donald Woods
For Geronimo, we also setup a Devtools subproject for our Eclipse plugins. I would suggest doing that for OpenJPA, as the maven builds are different enough that you don't want non-Eclipse users to deal with the delays of downloading an Eclipse runtime for the build steps. Also, you may want t

Re: Eclipse Plugin for OpenJPA

2009-02-23 Thread Daryl Stultz
On Mon, Feb 23, 2009 at 1:31 PM, Pinaki Poddar wrote: > > > What is the status of this request? > I just submitted it in response to your message today. I'll let you know if I hear anything. -- Daryl Stultz _ 6 Degrees Software and Consulting, Inc. http://ww

Re: Eclipse Plugin for OpenJPA

2009-02-23 Thread Pinaki Poddar
Hi Daryl, > Pinaki, I'm sure your plugin will be great, Thank you for your kind words. But I am really a novice in such matters. > but FYI I have added this as a feature request to the MyEclipseIDE plugin What is the status of this request? Please note that while implementing this plugin, I

Re: Eclipse Plugin for OpenJPA

2009-02-23 Thread Daryl Stultz
On Mon, Feb 23, 2009 at 10:55 AM, Pinaki Poddar wrote: > > Hi, > For Eclipse IDE users, a plugin is available to help development with > OpenJPA [1]. It adds a builder step to Java projects in Eclipse workspace > so > that all your persistent classes are bytecode enhanced as part of the > Eclips

@Id, @TableGenerator - Id creation fails when using a connection pool (inside Geronimo 2.1.3)

2009-02-23 Thread Norbert Rieger
Hi, until now I specified my jdbc connection in persistence.xml: MD When using a database connection pool (with

Re: Eclipse Plugin for OpenJPA

2009-02-23 Thread Pinaki Poddar
Hi Kevin, Why I considered starting to build a plugin for OpenJPA is two-fold: a) to estimate and experience first hand, what is the complexity involved in developing a Eclipse based tooling for OpenJPA with this prototype. Starting as a novice, the effort was equivalent to 4 person-days. b)

Re: Is the implementation of lock(LockModeType.READ) correct?

2009-02-23 Thread David Ezzio
Hi Philip, Yup, I agree with your argument, and it seems to me the conclusion shows that our example (either mine or the original one that you proposed and I expanded) doesn't really mirror what a bank would do. If it dispensed 175, it would likely zero out all three balances meaning that not

Re: Eclipse Plugin for OpenJPA

2009-02-23 Thread Kevin Sutter
Hi Pinaki, Thanks for starting this activity. I've noticed that OpenEJB has a separate project for the OpenEJB Eclipse Plugin. Maybe we should consider following the same path? Not sure if it's a lot of overhead to have a separate project like that or not. Thoughts? Kevin On Mon, Feb 23, 2009

Eclipse Plugin for OpenJPA

2009-02-23 Thread Pinaki Poddar
Hi, For Eclipse IDE users, a plugin is available to help development with OpenJPA [1]. It adds a builder step to Java projects in Eclipse workspace so that all your persistent classes are bytecode enhanced as part of the Eclipse's incremental compilation process. Please note that, at this point