[Hibernate-JIRA] Created: (HHH-5785) HQL UPDATE omits alias when referencing an entity
by Ondrej Medek (JIRA)
HQL UPDATE omits alias when referencing an entity
-------------------------------------------------
Key: HHH-5785
URL: http://opensource.atlassian.com/projects/hibernate/browse/HHH-5785
Project: Hibernate Core
Issue Type: Bug
Affects Versions: 3.3.1
Environment: Hibernate 3.3.1 in JBoss AS 5.1.0, org.hibernate.dialect.HSQLDialect
Reporter: Ondrej Medek
HQL UPDATE:
UPDATE Lesson e SET e.state = 'N' WHERE EXISTS (SELECT 1 FROM LessonOrder lso WHERE lso.lesson = e)
produces wrong SQL:
update LESSON set lsn_state='N' where exists (select 1 from LESSON_ORDER lessonorde1_ where lessonorde1_.lsn_id=lsn_id)
since in the database exists columns if the same name: LESSON.lsn_id and LESSON_ORDER.lsn_id. The problem is, that Hibernate omits the alias "e" in the SQL. When I make a little different query:
UPDATE Lesson e SET e.state = 'N' WHERE EXISTS (SELECT 1 FROM LessonOrder lso WHERE lso.lesson.id = e.id)
then the resulting SQL is right:
update LESSON set lsn_state='N' where exists (select 1 from LESSON_ORDER lessonorde1_ where lessonorde1_.lsn_id=LESSON.lsn_id)
However, I think the Hibernate should not omit the alias "e" in either case.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://opensource.atlassian.com/projects/hibernate/secure/Administrators....
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
13 years, 2 months
[Hibernate-JIRA] Created: (HHH-6702) mysql 51 test failures
by Strong Liu (JIRA)
mysql 51 test failures
----------------------
Key: HHH-6702
URL: http://opensource.atlassian.com/projects/hibernate/browse/HHH-6702
Project: Hibernate Core
Issue Type: Sub-task
Reporter: Strong Liu
org.hibernate.test.hql.ASTParserLoadingTest.testJPAQLQualifiedIdentificationVariablesControl
org.hibernate.test.hql.ASTParserLoadingTest.testPaginationWithPolymorphicQuery
org.hibernate.test.hql.ASTParserLoadingTest.testImplicitPolymorphism
org.hibernate.test.hql.ASTParserLoadingTest.testCachedJoinedAndJoinFetchedManyToOne
org.hibernate.test.hql.ASTParserLoadingTest.testCachedJoinedAndJoinFetchedOneToMany
org.hibernate.test.id.uuid.sqlrep.sqlbinary.UUIDBinaryTest.testUsage
org.hibernate.test.id.uuid.strategy.CustomStrategyTest.testUsage
org.hibernate.test.instrument.runtime.JavassistInstrumentationTest.testLazy
org.hibernate.test.instrument.runtime.JavassistInstrumentationTest.testCustomColumnReadAndWrite
org.hibernate.test.instrument.runtime.JavassistInstrumentationTest.testFetchAll
org.hibernate.test.instrument.runtime.JavassistInstrumentationTest.testLazyManyToOne
org.hibernate.test.instrument.runtime.JavassistInstrumentationTest.testPropertyInitialized
org.hibernate.test.querycache.QueryCacheTest.testCaseInsensitiveComparison
org.hibernate.test.sql.hand.query.NativeSQLQueriesTest.testTextTypeInSQLQuery
org.hibernate.test.sql.hand.query.NativeSQLQueriesTest.testImageTypeInSQLQuery
org.hibernate.test.tm.CMTTest.testConcurrentCachedDirtyQueries
org.hibernate.test.sql.hand.custom.mysql.MySQLCustomSQLTest.testScalarStoredProcedure
org.hibernate.test.sql.hand.custom.mysql.MySQLCustomSQLTest.testParameterHandling
org.hibernate.test.sql.hand.custom.mysql.MySQLCustomSQLTest.testEntityStoredProcedure
org.hibernate.test.sql.hand.custom.mysql.MySQLCustomSQLTest.testHandSQL
--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira
13 years, 2 months