EntiytManager's QueryImpl mishandles ordinal position of HQL-style positional parameters

Description

Even though JPAQL does not allow such a syntax, HQL allow JDBC-style positional parameters to be used (? as opposed to ?1 which JPA requires). Currently there is a bug in org.hibernate.ejb.QueryImpl which mishandles the ordinal position for these parameters causing them to be "off by one".

The symptom is an error like : java.lang.IllegalArgumentException: Unable to locate parameter with position [1]

Environment

None

Assignee

Steve Ebersole

Reporter

Steve Ebersole

Fix versions

Labels

None

backPortable

None

Suitable for new contributors

None

Requires Release Note

None

Pull Request

None

backportDecision

None

Components

Affects versions

Priority

Minor
Configure