Java org.hibernate.hql.ast.QuerySyntaxException
我得到了这个异常:org.hibernate.hql.ast.QuerySyntaxException:子树的意外结束 当我执行以下查询时:Java org.hibernate.hql.ast.QuerySyntaxException,java,hibernate,Java,Hibernate,我得到了这个异常:org.hibernate.hql.ast.QuerySyntaxException:子树的意外结束 当我执行以下查询时: <query name="fetchCSpecificationByAttIdExtId"> <![CDATA[from > CProductSpecifications where attributeId=:attributeId and > extractedProductId in (:extracted
<query name="fetchCSpecificationByAttIdExtId">
<![CDATA[from
> CProductSpecifications where attributeId=:attributeId and
> extractedProductId in (:extractedList)]]> </query>
调用此查询的服务方法是:
List<CProductSpecifications> cSpecList=(List<CProductSpecifications>)this.baseDao.findByNamedQueryAndNamedParam("fetchCSpecificationByAttIdExtId", new String[]{"attributeId","extractedList"},new Object[]{aid,extractedList});
List cSpecList=(List)this.baseDao.findByNamedQueryAndNamedParam(“fetchcsspecificationbyattidextid”,新字符串[]{“attributeId”,“extractedList”},新对象[]{aid,extractedList});
是否extractedList为空?试着先做一个空支票
List<CProductSpecifications> cSpecList=(List<CProductSpecifications>)this.baseDao.findByNamedQueryAndNamedParam("fetchCSpecificationByAttIdExtId", new String[]{"attributeId","extractedList"},new Object[]{aid,extractedList});