hibernate联合主键,使用insert select插入数据报错

语句如下:
INSERT INTO CasFinanceData (id.asCode,id.financeUpdateDate,asName) SELECT a.id.asCode,a.id.financeUpdateDate,a.asName FROM CasFinanceDataTemp a where a.id not in (SELECT id from CasFinanceData)
其中:CasFinanceData表结构与CasFinanceDataTemp一致,CasFinanceDataTemp作为临时表辅助进行数据导入操作。asCode、financeUpdateDate为联合主键。
报错信息如下:
Caused by: org.hibernate.QueryException: could not resolve property: of: com.miextreme.chinas.entity.CasFinanceData
at org.hibernate.persister.entity.AbstractPropertyMapping.propertyException(AbstractPropertyMapping.java:83)
at org.hibernate.persister.entity.AbstractPropertyMapping.toType(AbstractPropertyMapping.java:77)
at org.hibernate.persister.entity.AbstractEntityPersister.getSubclassPropertyTableNumber(AbstractEntityPersister.java:1995)
at org.hibernate.hql.internal.ast.tree.IntoClause.isSuperclassProperty(IntoClause.java:233)
at org.hibernate.hql.internal.ast.tree.IntoClause.visitPropertySpecNodes(IntoClause.java:175)
at org.hibernate.hql.internal.ast.tree.IntoClause.initializeColumns(IntoClause.java:157)
at org.hibernate.hql.internal.ast.tree.IntoClause.initialize(IntoClause.java:65)
at org.hibernate.hql.internal.ast.HqlSqlWalker.createIntoClause(HqlSqlWalker.java:1231)
at org.hibernate.hql.internal.antlr.HqlSqlBaseWalker.intoClause(HqlSqlBaseWalker.java:859)
at org.hibernate.hql.internal.antlr.HqlSqlBaseWalker.insertStatement(HqlSqlBaseWalker.java:499)
at org.hibernate.hql.internal.antlr.HqlSqlBaseWalker.statement(HqlSqlBaseWalker.java:273)
at org.hibernate.hql.internal.ast.QueryTranslatorImpl.analyze(QueryTranslatorImpl.java:278)
at org.hibernate.hql.internal.ast.QueryTranslatorImpl.doCompile(QueryTranslatorImpl.java:206)
... 66 more

求高手解。

你可能感兴趣的:(hibernate联合主键,使用insert select插入数据报错)