gpt4 book ai didi

java - 线程中的异常 "main"org.hibernate.HibernateException : Could not parse

转载 作者:行者123 更新时间:2023-12-02 13:19:22 26 4
gpt4 key购买 nike

我是 hibernate 新手,并尝试运行第一个应用程序,但收到此错误:


“-//Hibernate/Hibernate配置DTD 3.0//EN”
“http://hibernate.sourceforge.net/hibernate-configuration-3.0.dtd”>

<hibernate-configuration>  

<session-factory>
<property name="hbm2ddl.auto">update</property>
<property name="dialect">org.hibernate.dialect.MySQLDialect</property>
<property name="connection.url">jdbc:mysql://localhost:3306/test</property>
<property name="connection.username">root</property>
<property name="connection.password">prashant</property>
<property name="connection.driver_class"> com.mysql.jdbc.Driver</property>
<mapping resource="employee.hbm.xml"/>
</session-factory>

</hibernate-configuration>

最佳答案

您的 hibernate.cfg.xml 中似乎有一些无效的 xml,因为它无法解析。

尝试将文件中的内容发布到此处,以便我们查看。

关于java - 线程中的异常 "main"org.hibernate.HibernateException : Could not parse,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/43627814/

26 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com