Skip to content

Commit f1cf0ab

Browse files
committed
fixes #1068
1 parent f9a115c commit f1cf0ab

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
@@ -1332,7 +1332,7 @@ String RelObjectNameWithoutValue() :
13321332
| tk=<K_READ> | tk=<K_SCHEMA> | tk=<K_SIZE> | tk=<K_SESSION>
13331333
| tk=<K_VIEW> | tk=<K_NOLOCK> | tk=<K_VALIDATE> | tk=<K_CYCLE> | tk=<K_OF> | tk=<K_EXCLUDE>
13341334
/*| tk=<K_PLACING> | tk=<K_BOTH> | tk=<K_LEADING> | tk=<K_TRAILING> */
1335-
| tk=<K_FORMAT>
1335+
| tk=<K_FORMAT> | tk=<K_DIV>
13361336
)
13371337

13381338
{ return tk.image; }

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

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4321,4 +4321,9 @@ public void testIssue1062() throws JSQLParserException {
43214321
public void testIssue1062_2() throws JSQLParserException {
43224322
assertSqlCanBeParsedAndDeparsed("SELECT * FROM mytable WHERE temperature.timestamp <= @until AND temperature.timestamp >= @from");
43234323
}
4324+
4325+
@Test
4326+
public void testIssue1068() throws JSQLParserException {
4327+
assertSqlCanBeParsedAndDeparsed("SELECT t2.c AS div");
4328+
}
43244329
}

0 commit comments

Comments
 (0)