-
-
Notifications
You must be signed in to change notification settings - Fork 1.4k
Closed
Description
Hi,
After upgrade to 4.4 from 3.1 I got some exceptions in some of my legal Mariadb SQL queries. After a bit of investigation, it turns out that some table aliases gives a parsing exception. The ones I can see which I think should be legal are rr,rs and ur.
I tested in on 4.3, and it works in 4.3.
Failing test
@Test
public void failingSQLURAlias() throws Exception {
String query = "select * from some_table ur\n";
CCJSqlParserUtil.parse(query);
}
@Test
public void failingSqlRRAlias() throws Exception {
String query = "select * from some_table rr\n";
CCJSqlParserUtil.parse(query);
}
@Test
public void failingSqlRSAlias() throws Exception {
String query = "select * from some_table rs\n";
CCJSqlParserUtil.parse(query);
}
Each of the tests give a parsing error like this:
net.sf.jsqlparser.JSQLParserException: Encountered unexpected token: "rs" <K_ISOLATION>
at line 1, column 26.
Was expecting one of:
";"
"ACTION"
"ACTIVE"
"ALGORITHM"
"ARCHIVE"
"ARRAY"
"AS"
"AT"
"BYTE"
"CASCADE"
"CASE"
......
Regards
Rolf Woll
Metadata
Metadata
Assignees
Labels
No labels