]
Steve Ebersole commented on HIBERNATE-106:
------------------------------------------
This is not the correct project to report Hibernate issues under. This Jira project is for
reporting issues in the integration between Hibernate and WildFly. To report issues in
Hibernate, please use
. Thanks.
Criteria + Example + Projections = "Y1_": invalid
identifier
------------------------------------------------------------
Key: HIBERNATE-106
URL:
https://issues.jboss.org/browse/HIBERNATE-106
Project: Hibernate Integration
Issue Type: Bug
Environment: Hibernate 3.3.1
Oracle 10
Sun JVM 1.5
Reporter: Krasimir Goutcev
Assignee: Steve Ebersole
When trying someting like this:
SystemClassif sc=new SystemClassif();
//sc.setTekst("??????????");
sc.setTekst("123");
Example sample=Example.create(sc).enableLike(MatchMode.ANYWHERE);
session.createCriteria(SystemClassif.class).setProjection(
Projections.projectionList()
.add(Projections.property("code"),"code")
.add(Projections.property("tekst"),"tekst")
).add(sample);
hibernate trying to execute this SQL:
select this_.ID as y0_, this_.TEKST as y1_ from SP.ADM_SYSTEM_CLASSIF this_ where (y1_
like ?)
and throus exception:
ORA-00904: "Y1_": invalid identifier
this happen only if we using Example AND property name AND alias are identical strings.