继续配置spring data jpa 在tomcat中

如果删掉持久单元,在建一个同样的持久单元,在有的工程中要报编译错误
注: Creating static metadata factory ...
注: Optional file was not found: META-INF/orm.xml continuing with generation.
注: Optional file was not found: META-INF/eclipselink-orm.xml continuing with generation.
注: Hibernate JPA 2 Static-Metamodel Generator 1.3.0.Final
错误: Problem with Filer: Attempt to recreate a file for type htm.NewEntity_
1 个错误
/root/NetBeansProjects/WebApplication3/nbproject/build-impl.xml:874: The following error occurred while executing this line:
/root/NetBeansProjects/WebApplication3/nbproject/build-impl.xml:296: Compile failed; see the compiler error output for details.
构建失败 (总时间: 2 秒)
但是,同样的操作,在有的工程中则没有,具体原因未知
在配置Spring Data Jpa的过程中,如果遇到
持久层采用Eclipselink的话,遇到eclipselink.weaving错误的话,在持久单元中加入
<property name="eclipselink.weaving" value="false"/>
如果遇到hibernate.dialect错误
设置hibernate.dialect
RDBMS  方言
DB2  org.hibernate.dialect.DB2Dialect
DB2 AS/400  org.hibernate.dialect.DB2400Dialect
DB2 OS390  org.hibernate.dialect.DB2390Dialect
PostgreSQL  org.hibernate.dialect.PostgreSQLDialect
MySQL  org.hibernate.dialect.MySQLDialect
MySQL with InnoDB  org.hibernate.dialect.MySQLInnoDBDialect
MySQL with MyISAM  org.hibernate.dialect.MySQLMyISAMDialect
Oracle (any version)  org.hibernate.dialect.OracleDialect
Oracle 9i/10g  org.hibernate.dialect.Oracle9Dialect
Sybase  org.hibernate.dialect.SybaseDialect
Sybase Anywhere  org.hibernate.dialect.SybaseAnywhereDialect
Microsoft SQL Server  org.hibernate.dialect.SQLServerDialect
SAP DB  org.hibernate.dialect.SAPDBDialect
Informix  org.hibernate.dialect.InformixDialect
HypersonicSQL  org.hibernate.dialect.HSQLDialect
Ingres  org.hibernate.dialect.IngresDialect
Progress  org.hibernate.dialect.ProgressDialect
Mckoi SQL  org.hibernate.dialect.MckoiDialect
Interbase  org.hibernate.dialect.InterbaseDialect
Pointbase  org.hibernate.dialect.PointbaseDialect
FrontBase  org.hibernate.dialect.FrontbaseDialect
Fclass="or fw600"irebird  org.hibernate.dialect.FirebirdDialect
自己去找对应的值,我用Mysql,就用org.hibernate.dialect.MySQLDialect
  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值