hibernate配置文件

<?xml version='1.0' encoding='UTF-8'?>
<!DOCTYPE hibernate-configuration PUBLIC
"-//Hibernate/Hibernate Configuration DTD 3.0//EN"
"http://www.hibernate.org/dtd/hibernate-configuration-3.0.dtd">
<hibernate-configuration>

  <session-factory>
    <property name="dialect">org.hibernate.dialect.MySQLDialect</property>
    <property name="connection.url">jdbc:mysql://localhost:3306/cloud_note</property>
    <property name="connection.username">root</property>
    <property name="connection.password">admin</property>
    <property name="connection.driver_class">com.mysql.jdbc.Driver</property>
    <property name="show_sql">true</property>
    <property name="format_sql">true</property>

    <!-- 加载映射描述文件 -->
    <mapping resource="User.hbm.xml" />

  </session-factory>

</hibernate-configuration>

posted on 2017-01-23 09:38  xyz23  阅读(109)  评论(0编辑  收藏  举报

导航