Skip to content

Commit d01e602

Browse files
committed
HHH-6672 - Remove UNION support from 5.x grammars
(cherry picked from commit dd4f809)
1 parent 0e999e8 commit d01e602

File tree

2 files changed

+2
-13
lines changed

2 files changed

+2
-13
lines changed

hibernate-core/src/main/antlr/hql.g

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -74,7 +74,6 @@ tokens
7474
SOME="some";
7575
SUM="sum";
7676
TRUE="true";
77-
UNION="union";
7877
UPDATE="update";
7978
VERSIONED="versioned";
8079
WHERE="where";
@@ -298,10 +297,6 @@ insertablePropertySpec
298297
}
299298
;
300299
301-
union
302-
: queryRule (UNION queryRule)*
303-
;
304-
305300
//## query:
306301
//## [selectClause] fromClause [whereClause] [groupByClause] [havingClause] [orderByClause];
307302
@@ -805,7 +800,7 @@ compoundExpr
805800
;
806801

807802
subQuery
808-
: union
803+
: queryRule
809804
{ #subQuery = #([QUERY,"query"], #subQuery); }
810805
;
811806

hibernate-core/src/test/java/org/hibernate/test/hql/HqlParserTest.java

Lines changed: 1 addition & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -33,13 +33,7 @@
3333
* works properly (i.e. no unexpected syntax errors).
3434
* todo this should be a unit test.
3535
*/
36-
public class HqlParserTest{
37-
38-
39-
@Test
40-
public void testUnion() throws Exception {
41-
parse("from Animal a where a in (from Cat union from Dog) ");
42-
}
36+
public class HqlParserTest {
4337

4438
/**
4539
* Section 9.2 - from *

0 commit comments

Comments
 (0)