Win a copy of Re-engineering Legacy Software this week in the Refactoring forum
or Docker in Action in the Cloud/Virtualization forum!
    Bookmark Topic Watch Topic
  • New Topic

createEntityManagerFactory is null

 
tarik el berrak
Greenhorn
Posts: 29
  • Mark post as helpful
  • send pies
  • Report post to moderator
Hi all,

I have a problem with my jpa project.

here is the persistence file:
----------------------------------------------------------------------------
<persistence xmlns="http://java.sun.com/xml/ns/persistence"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://java.sun.com/xml/ns/persistence
http://java.sun.com/xml/ns/persistence/persistence_1_0.xsd" version="1.0">
<persistence-unit name="QuotePickerPU" transaction-type="RESOURCE_LOCAL">
<provider>org.hibernate.ejb.HibernatePersistence</provider>
<class>com.quotepicker.beans.QuoteBean</class>
<class>com.quotepicker.beans.CompanyBean</class>
<class>com.quotepicker.beans.QuoteBeanId</class>
<properties>
<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"/>
</properties>
</persistence-unit>
----------------------------------------------------------------------------

i get null when calling this

emf = Persistence.createEntityManagerFactory("QuotePickerPU");




any ideas ??

Thanks in advance
 
Jaikiran Pai
Marshal
Pie
Posts: 10444
227
IntelliJ IDE Ubuntu
  • Mark post as helpful
  • send pies
  • Report post to moderator
Please do not post the same question in multiple forums. Let's continue this discussion in your other thread at http://www.coderanch.com/t/418901/java-EJB-SCBCD/certification/createEntityManagerFactory-null
 
    Bookmark Topic Watch Topic
  • New Topic