File tree Expand file tree Collapse file tree 4 files changed +22
-0
lines changed
main/antlr4/org/springframework/data/jpa/repository/query
test/java/org/springframework/data/jpa/repository/query Expand file tree Collapse file tree 4 files changed +22
-0
lines changed Original file line number Diff line number Diff line change @@ -768,6 +768,7 @@ reservedWord
768768 | JOIN
769769 | KEY
770770 | LAST
771+ | LATERAL
771772 | LEADING
772773 | LEFT
773774 | LIKE
Original file line number Diff line number Diff line change @@ -1026,4 +1026,11 @@ void entityNameWithPackageContainingReservedWord(String reservedWord) {
10261026 String source = "select new com.company.%s.thing.stuff.ClassName(e.id) from Experience e" .formatted (reservedWord );
10271027 assertQuery (source );
10281028 }
1029+
1030+ @ Test // GH-3496
1031+ void lateralShouldBeAValidParameter () {
1032+
1033+ assertQuery ("select e from Employee e where e.lateral = :_lateral" );
1034+ assertQuery ("select te from TestEntity te where te.lateral = :lateral" );
1035+ }
10291036}
Original file line number Diff line number Diff line change @@ -1568,6 +1568,13 @@ void typeShouldBeAValidParameter() {
15681568 assertQuery ("select te from TestEntity te where te.type = :type" );
15691569 }
15701570
1571+ @ Test // GH-3496
1572+ void lateralShouldBeAValidParameter () {
1573+
1574+ assertQuery ("select e from Employee e where e.lateral = :_lateral" );
1575+ assertQuery ("select te from TestEntity te where te.lateral = :lateral" );
1576+ }
1577+
15711578 @ Test // GH-3099
15721579 void functionNamesShouldSupportSchemaScoping () {
15731580
Original file line number Diff line number Diff line change @@ -965,6 +965,13 @@ void typeShouldBeAValidParameter() {
965965 assertQuery ("select te from TestEntity te where te.type = :type" );
966966 }
967967
968+ @ Test // GH-3496
969+ void lateralShouldBeAValidParameter () {
970+
971+ assertQuery ("select e from Employee e where e.lateral = :_lateral" );
972+ assertQuery ("select te from TestEntity te where te.lateral = :lateral" );
973+ }
974+
968975 @ Test // GH-3061
969976 void alternateNotEqualsOperatorShouldWork () {
970977 assertQuery ("select e from Employee e where e.firstName != :name" );
You can’t perform that action at this time.
0 commit comments