您可以在创建时提供其他属性
EntityManagerFactory:
Map<String, String> properties = new HashMap<String, String>();properties.put("javax.persistence.jdbc.user", ...);...emf = Persistence.createEntityManagerFactory("dbstats", properties);
您可以在创建时提供其他属性
EntityManagerFactory:
Map<String, String> properties = new HashMap<String, String>();properties.put("javax.persistence.jdbc.user", ...);...emf = Persistence.createEntityManagerFactory("dbstats", properties);