Re: change entity mapping table in runtime

2013-04-11 Thread Rick Curtis
I'm not certain this is the right answer, but with a bit of hacking I was able to get the behavior you are looking for // Get a reference to the mapping repository MappingRepository repo = (MappingRepository) ((EntityManagerImpl) em).getConfiguration().getMetaDataRepositoryInstance(); // Get

What is the type parameter, 'X' for?

2013-04-11 Thread Chris Wolf
... in this interface? public interface OpenJPAQueryX extends TypedQueryX (an example would be good also) Thanks, Chris

Re: What is the type parameter, 'X' for?

2013-04-11 Thread Pawel Veselov
On Thu, Apr 11, 2013 at 1:24 PM, Chris Wolf cwolf.a...@gmail.com wrote: ... in this interface? public interface OpenJPAQueryX extends TypedQueryX (an example would be good also) X is the class of the objects that the query is supposed to return. TypedQueryEAgent agents =

Re: What is the type parameter, 'X' for?

2013-04-11 Thread Rick Curtis
X is the query result type. TypedQueryCustomer q = em.createQuery(Select c FROM Customer c , Customer.class); Thanks, Rick On Thu, Apr 11, 2013 at 3:24 PM, Chris Wolf cwolf.a...@gmail.com wrote: ... in this interface? public interface OpenJPAQueryX extends TypedQueryX (an example would

Re: What is the type parameter, 'X' for?

2013-04-11 Thread Chris Wolf
Thanks, Pawel, Yes, I normally try to stick with just javax.persistence API, but I wanted to force fetching entire object graph and I thought eager fetching would do that, as shown here: http://openjpa.apache.org/builds/1.0.3/apache-openjpa-1.0.3/docs/manual/ref_guide_perfpack_eager.html