Skip to content
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

Ensure QueryBuilder interface detects empty enumerables in query AST #2

Open
ngetahun opened this issue Sep 16, 2020 · 0 comments
Open

Comments

@ngetahun
Copy link

The Arel builders work well but because SOQL is not SQL conformant, certain queries don't work

For example:

SELECT Id from Account WHERE 1=0 AND SomeField=true

Although this is a valid SQL query, SOQL cannot parse this correctly. One reason why QueryBuilder injects 1=0 is when an empty enumerable is given as argument. To solve this we should validate empty enumerable during AST build.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant