<?xml version='1.0' encoding='utf-8'?>
<!DOCTYPE hibernate-configuration
    PUBLIC "-//Hibernate/Hibernate Configuration DTD//EN"
    "http://hibernate.sourceforge.net/hibernate-configuration-3.0.dtd"><hibernate-configuration>    <session-factory>        <property name="hibernate.connection.driver_class">org.gjt.mm.mysql.Driver</property>        <property name="hibernate.connection.url">jdbc:mysql://localhost/student</property>        <property name="hibernate.connection.username">root</property>        <property name="hibernate.connection.password">root</property>        <property name="hibernate.connection.pool_size">100</property>        <property name="show_sql">true</property>        <property name="dialect">org.hibernate.dialect.MySQLDialect</property>
        
        <property name="hibernate.cache.use_query_cache">true</property>

        <mapping resource="student.hbm.xml"/>    </session-factory></hibernate-configuration>不知道是什么错误
发一个正确的你看看吧

解决方案 »

  1.   

    hibernate.cfg.xml没有写对。参照对的自己察看。那语句本身是对的!
      

  2.   

    这哪看得出来啊,要看hibernate.cfg.xml里的代码啊··
      

  3.   

    楼上说的不对,应该是路径的问题。
    configure()里面不放参数的话,程序会从当前路径下找,你可以指定一下路径。你配置文件放的地方有问题,导致找不到。
      

  4.   

    配置文件有问题
    The up in the document preceding the root element must be well-formed.
    仔细查看一下。