hibernate 项目启动时总会自动创建表

时间:2020-01-16 11:19:23   收藏:0   阅读:119

 

hibernate 项目启动时总会自动创建表,造成以下错误

Caused by: java.sql.SQLSyntaxErrorException: ORA-00955: 名称已由现有对象使用

  经验证,是方言使用错误导致的。项目使用的数据库版本为Oracle11g,方言应该使用  org.hibernate.dialect.Oracle10gDialect

 

修改配置如下:

  jpa:
    show-sql: true
    database-platform: org.hibernate.dialect.Oracle10gDialect
    properties:
      hibernate:
        hbm2ddl:
          auto: update

  

 

原文:https://www.cnblogs.com/Leechg/p/12199685.html

评论(0
© 2014 bubuko.com 版权所有 - 联系我们:wmxa8@hotmail.com
打开技术之扣,分享程序人生!