Once there's a string "call" involved in an hql, hibernate will throw an exception like the one below:
HibernateSystemException: ordinal parameter mismatch
This is an open bug reported here:
http://opensource.atlassian.com/projects/hibernate/browse/HHH-1423
A simple workaround is to make the 'call' variable the first in the query
before:
after
HibernateSystemException: ordinal parameter mismatch
This is an open bug reported here:
http://opensource.atlassian.com/projects/hibernate/browse/HHH-1423
A simple workaround is to make the 'call' variable the first in the query
before:
from Ship s where s.name = ? and s.callsign = ?
after
from Ship s where s.callsign = ? and s.name = ?
本文介绍了一个关于Hibernate HQL查询中使用call关键字导致的参数顺序错误异常,并提供了一种简单的解决方案。
1545

被折叠的 条评论
为什么被折叠?



