JPA exception: Object: … is not a known entity type

后端 未结 11 658

I\'m new to JPA and I\'m having problems with the autogeneration of primary key values.

I have the following entity:

package jpatest.entities;

impor         


        
11条回答
  •  渐次进展
    2020-12-10 03:27

    You could try and leave the definition out of the persistnce.xml The Persistence provider should than scan all classes in the classpath for @Entity annotations.

提交回复
热议问题