File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes Object Relational Mapping and the fly likes jpa problems Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Murach's Java Servlets and JSP this week in the Servlets forum!
JavaRanch » Java Forums » Databases » Object Relational Mapping
Bookmark "jpa problems" Watch "jpa problems" New topic
Author

jpa problems

Kevin Pang
Ranch Hand

Joined: Mar 01, 2005
Posts: 38
can i load the persistence.xml in my java code? and the persistence.xml is not in the "META-INF" folder.
how to achieve this?

thanks in adv.
Devaka Cooray
ExamLab Creator
Saloon Keeper

Joined: Jul 29, 2008
Posts: 3013
    
  35

Kevin Pang wrote:can i load the persistence.xml in my java code?


What did you mean by this?


Founder of ExamLab and Systemup
See how I can help you to become an awesome programmer
Kevin Pang
Ranch Hand

Joined: Mar 01, 2005
Posts: 38
i want to load the persistence.xml by my java source code, not by toplink jpa, so i can load the persistence.xml from outside the jar file directory META-INF.
Kevin Pang
Ranch Hand

Joined: Mar 01, 2005
Posts: 38
I found in toplink src class:
oracle.toplink.essentials.ejb.cmp3.EntityManagerFactoryProvider



any solution to modify the persistence configuration file path without change toplink source ?
 
 
subject: jpa problems
 
Similar Threads
Standalone JPA example
Bind the server IP to the EJB JNDI name
EJB can't find Optional Package and thus Persistence Unit in it
EAR packaging - @Persistence Unit injection fails
No Persistence provider for EntityManager named.....