必选项:
hibernate.connection.username:访问的数据库用户名
hibernate.connection.password:访问的数据库密码
hibernate.connection.url:连接数据库的url
hibernate.connection.driver_class:连接数据库使用的驱动程序
hibernate.dialect:连接数据库所使用的方言
可选项:
show_sql:显示执行的sql语句
常见数据库的驱动程序、url、方言 1. mysql驱动程序为:"com.mysql.jdbc.Driver", url为:"jdbc:mysql://localhost:3306/[DBName]"。方言:org.hibernate.dialect.MySQLDialect
mysql的一个配置样例
org.hibernate.dialect.MySQLDialect jdbc:mysql://localhost/test com.mysql.jdbc.Driver root han true