Home > database >  Org. Hibernate. QueryParameterException: could not locate the parameter [payStatus]
Org. Hibernate. QueryParameterException: could not locate the parameter [payStatus]

Time:09-27


Public int updatePayStatus (String orderNo) {
String HQL="";
Map The map=new HashMap (a);
{if (StringUtils. IsNotBlank (orderNo))
HQL=HQL + "update CClaimTtOrderEO t set t.p ayStatus='1' where t.o rderNo=" orderNo ";
The map. The put (" payStatus ", "1");
The map. The put (" orderNo ", orderNo);
Logger. The info (" updatePayStatus (), conditionMap={} ", map);
}
Return super. BulkUpdate (HQL, map);
}


error : org. Hibernate. QueryParameterException: could not locate the parameter [payStatus]
Consult everybody what reason is this?

CodePudding user response:

Don't understand HQL, seems to be

HQL=HQL + "update CClaimTtOrderEO t set t.p ayStatus='1' where t.o rderNo=" orderNo ";
The map. The put (" payStatus ", "1");
The map. The put (" orderNo ", orderNo);


Seek a parameter, but entered two parameters,

CodePudding user response:

Well, get rid of the first parameter to try

CodePudding user response:

Well, get rid of the first parameter to try
  • Related