0 Replies Latest reply on Mar 4, 2006 4:55 PM by tibocu

    presistence.xml with j2se

    tibocu

      Hi,

      I run a j2se application with jax.persistence, but I cannot get the EntityManagerFactory declared in the persistence.xml file.

      My code:
      factory = Persistence.createEntityManagerFactory("em");

      I get: No Persistence provider for EntityManager named em

      The persistence.xml file is located in src/META-INF/persistence.xml

      The application is compiled in the classes directory, with the META-INF/persistence.xml copied.

      The application is not packaed in a jar.

      Shoudl works ?

      Tks