New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[plsql] Parsing exception "Less than or equal to/Greater than or equal to" operators in DML statements #3746
Comments
Do you know if there can be a newline or comments between the two symbols, or just spaces? |
Very good question @oowekyala. Yes, you can. Oracle allows you to put not just spaces, you can put new lines, even comments between the two symbols, and the database engine compiles the routine correctly. |
In that case I believe it would be enough to lex |
I am not sure about your comment @oowekyala, is it possible to fix it in PMD parser? |
Yes, this was more of a note to myself |
…or equal to" operators in DML statements
…or equal to" operators in DML statements
…or equal to" operators in DML statements
Affects PMD Version:
This error was testing in the following versions:
Description:
Trying to analyze pl/sql code that has "Less than or equal to/Greater than or equal to" operators (<=; >=), but these operators have a blank space between two characters, for instance > = or < =, PMD raises an exception error indicating "Error while parsing".
Note: This is totally correct in DML statements for Oracle databases engines.
Exception Stacktrace:
Code Sample demonstrating the issue:
Note: By removing all the blank spaces in the operators in the SELECT statement, you will have no parsing problems.
Steps to reproduce:
Running PMD through: [CLI]
The text was updated successfully, but these errors were encountered: