Skip to content

Commit 144e60b

Browse files
committed
fixes #876
1 parent 25e1dcc commit 144e60b

File tree

2 files changed

+6
-1
lines changed

2 files changed

+6
-1
lines changed

src/main/jjtree/net/sf/jsqlparser/parser/JSqlParserCC.jjt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1134,7 +1134,7 @@ String RelObjectNameWithoutValue() :
11341134
| tk=<K_TEMP> | tk=<K_TEMPORARY> | tk=<K_TYPE> | tk=<K_ISNULL>
11351135
| tk=<K_ZONE> | tk=<K_COLUMNS> | tk=<K_DESCRIBE> | tk=<K_FN> | tk=<K_PATH>
11361136
| tk=<K_DATE_LITERAL> | tk=<K_NEXTVAL> | tk=<K_TRUE> | tk=<K_FALSE> | tk=<K_DUPLICATE>
1137-
| tk=<K_READ> | tk=<K_SIZE>
1137+
| tk=<K_READ> | tk=<K_SIZE> | tk=<K_SESSION>
11381138
/* | tk=<K_PLACING> | tk=<K_BOTH> | tk=<K_LEADING> | tk=<K_TRAILING> */
11391139
)
11401140

src/test/java/net/sf/jsqlparser/statement/select/SelectTest.java

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3892,4 +3892,9 @@ public void testPartitionByWithBracketsIssue865() throws JSQLParserException {
38923892
public void testWithAsRecursiveIssue874() throws JSQLParserException {
38933893
assertSqlCanBeParsedAndDeparsed("WITH rn AS (SELECT rownum rn FROM dual CONNECT BY level <= (SELECT max(cases) FROM t1)) SELECT pname FROM t1, rn WHERE rn <= cases ORDER BY pname");
38943894
}
3895+
3896+
@Test
3897+
public void testSessionKeywordIssue876() throws JSQLParserException {
3898+
assertSqlCanBeParsedAndDeparsed("SELECT ID_COMPANY FROM SESSION.COMPANY");
3899+
}
38953900
}

0 commit comments

Comments
 (0)