JSqlParser
JSqlParser copied to clipboard
postgres `@` for abs number doesn't work
Describe the bug A clear and concise description of what the bug is.
To Reproduce Steps to reproduce the behavior:
-
select @(-1)
- Parsing this SQL using JSqlParser with this statements
org.junit.ComparisonFailure: Expected query to parse but it failed to parse (error: Encountered unexpected token: "(" "("
at line 1, column 9.
Expected behavior query parses, docs here https://www.postgresql.org/docs/9.5/functions-math.html
select abs(-1)
works
System
- postgres
- Java11
- JSqlParser 4.2
Not supported in JSQLParser (and if you ask me, Postgres should not support this either). I can only guess that this an Ingres heritage.
You best bet would be to submit a PR.
Sorry, but to be honest regarding readability this is IMHO a disaster. :/