Hibernate常用配置

hibernate.dialect   说明要用Hibernate连接哪种类型的数据库服务器
hibernate.autoReconnect  (true/false)  Hibernate连接数据库超时设置
hibernate.connection.autocommit  (true/false)   自动提交事务
hibernate.show_sql  (true/false)   是否在后台显示Hibernate用到的SQL语句,选择true便于查错,选择false,提高运行效率
hibernate.max_fetch_depth  (0~3)  外连接抓取深度
hibernate.connection.driver_class   配置数据库的驱动程序,Hibernate在连接数据库时,需要用到数据库的驱动程序
hibernate.connection.url  设置数据库连接
hibernate.hbm2ddl.auto  属性设置和对应效果


posted on 2019-10-21 10:33  MarcoRe  阅读(201)  评论(0)    收藏  举报

导航