我收到错误
org.hibernate.HibernateException: Errors in named queries: GroupKPI.deleteKPIList
在此查询中:
@NamedQuery(name="GroupKPI.deleteKPIList" , query="delete from GroupKPI kpi where kpi.kpiKey in :list2BDeleted")
课程:
@Entity
@Table(name="GROUP_KPI")
public class GroupKPI implements Serializable{
public GroupKPI() { }
@EmbeddedId
private GroupKpiKey kpiKey;
.
.
.
.
.
}
我需要将GroupKPI
列表传递给查询
我正在使用hibernate 3.3.0
编辑:
整个日志:
org.hibernate.QueryException: query must begin with SELECT or FROM: delete
我发现here错误是通过应用解析器org.hibernate.hql.ast.ASTQueryTranslatorFactory
来修复的,但项目很旧并且可能有一些旧查询,因此解析器无法安全更改...所以任何其他建议或替代语法?