We're updating the issue view to help you get more done. 

String literals in an HQL query can get mangled

Description

When calling Session.createQuery() with the query string
"FROM Phase phase WHERE phase.comment= 'This is a test, Phase 1'"
it is turned into
"FROM com.example.Phase phase WHERE phase.comment= 'This is a test, com.example.Phase 1'"
as shown by log output in the QueryTranslatorImpl. This is, to put it mildly, highly surprising and undesirable behaviour.

The trigger seems to be the sequence <Comma Space Entity-Name>, which triggers a transformation of the entity name into the fully qualified class name even in string literals, where that has no business happening whatsoever.

Environment

None

Status

Assignee

Andrea Boriero

Reporter

Daniel Gudlat

Components

Fix versions

Affects versions

4.1.9
5.0.7

Priority

Major