運行時報錯INFO: HCANN000001: Hibernate Commons Annotations {4.0.2.Final},求大神解決
//hibernate.cfg.xml的內容
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE hibernate-configuration PUBLIC
? ? ? ? ? "-//Hibernate/Hibernate Configuration DTD 3.0//EN"
? ? ? ? ? "http://hibernate.sourceforge.net/hibernate-configuration-3.0.dtd">
<hibernate-configuration>
<session-factory>
<property name="connection.username">root</property>
<property name="connection.password">root</property>
<property name="connection.driver_class">com.mysql.jdbc.Driver</property>
<property name="connection.url">jdbc:mysql:///hibernate?useUnicode=true&characterEncoding=UTF-8</property>
<property name="dialect">org.hibernate.dialect.MySQLDialect</property>
<mapping resource="root/hibernate/Students.hbm.xml"/>
</session-factory>
</hibernate-configuration>
//報的錯誤是:
十月 13, 2015 9:36:57 上午 org.hibernate.annotations.common.Version <clinit>
INFO: HCANN000001: Hibernate Commons Annotations {4.0.2.Final}
十月 13, 2015 9:36:57 上午 org.hibernate.Version logVersion
INFO: HHH000412: Hibernate Core {4.2.4.Final}
十月 13, 2015 9:36:57 上午 org.hibernate.cfg.Environment <clinit>
INFO: HHH000206: hibernate.properties not found
十月 13, 2015 9:36:57 上午 org.hibernate.cfg.Environment buildBytecodeProvider
INFO: HHH000021: Bytecode provider name : javassist
十月 13, 2015 9:36:57 上午 org.hibernate.cfg.Configuration configure
INFO: HHH000043: Configuring from resource: /hibernate.cfg.xml
十月 13, 2015 9:36:57 上午 org.hibernate.cfg.Configuration getConfigurationInputStream
INFO: HHH000040: Configuration resource: /hibernate.cfg.xml
2017-06-02
我把lib里的jar包換了一下 就可以用了 ?換成了和老師做的一樣的
2016-05-08
我們的問題出現的一樣啊
2016-04-30
樓主,我和你遇到一樣的問題,請問你最后解決了沒?
2016-01-22
INFO: HHH000206: hibernate.properties not found
沒找到你的配置文檔,你要把hibernate.properties.xml放到src目錄下哦~