JPA with TopLink: No META-INF/persistence.xml was found in classpath

后端 未结 7 2362
孤独总比滥情好
孤独总比滥情好 2020-12-19 03:04
public class LoginTest {

public static void main(String[] args) {
    EntityManagerFactory emf = Persistence.createEntityManagerFactory(\"IRCBotPU\");
    EntityMan         


        
7条回答
  •  猫巷女王i
    2020-12-19 03:56

    I created a folder callled META-INF under src and it works. "marcosbeirigo" answered it already. I do not know why I have to put that persistance.xml in there though. I put it under WebContent/META-INF and did not work

提交回复
热议问题