File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
The moose likes EJB and other Java EE Technologies and the fly likes createEntityManagerFactory is null Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » EJB and other Java EE Technologies
Reply locked New topic

createEntityManagerFactory is null

tarik el berrak

Joined: Oct 06, 2006
Posts: 29
Hi all,

I have a problem with my jpa project.

here is the persistence file:
<persistence xmlns=""
xsi:schemaLocation="" version="1.0">
<persistence-unit name="QuotePickerPU" transaction-type="RESOURCE_LOCAL">
<property name="hibernate.connection.driver_class" value="com.mysql.jdbc.Driver" />
<property name="hibernate.connection.url" value="jdbc:mysql://localhost:3306/trainning" />
<property name="hibernate.connection.username" value="root"/>

i get null when calling this

emf = Persistence.createEntityManagerFactory("QuotePickerPU");

any ideas ??

Thanks in advance

SCJP 1.5<br />New Target (SCWCD 5)
Jaikiran Pai

Joined: Jul 20, 2005
Posts: 10441

Please do not post the same question in multiple forums. Let's continue this discussion in your other thread at

[My Blog] [JavaRanch Journal]
I agree. Here's the link:
subject: createEntityManagerFactory is null
It's not a secret anymore!