<hibernate-configuration>
<session-factory>
<propertyname="hibernate.connection.driver_class">com.mysql.jdbc.Driver</property><!--设置驱动 -->
<propertyname="hibernate.connection.url">jdbc:mysql://localhost:3306/hibernate_first</property><!--设置数据库url -->
<propertyname="hibernate.connection.username">root</property><!-- 设置用户命 -->
<propertyname="hibernate.connection.password">root</property><!-- 设置密码 -->
<propertyname="hibernate.dialect">org.hibernate.dialect.HSQLDialect</property><!--设置方言:翻译成mysql语句 -->
</session-factory>
</hibernate-configuration>
【Hibernate】数据库配置
最新推荐文章于 2022-12-29 15:13:57 发布