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

Brackets to group expressions doesn't seem to work #17

Open
Yutsa opened this issue Nov 3, 2023 · 1 comment
Open

Brackets to group expressions doesn't seem to work #17

Yutsa opened this issue Nov 3, 2023 · 1 comment
Labels
enhancement New feature or request

Comments

@Yutsa
Copy link

Yutsa commented Nov 3, 2023

I am building a query with several AND and OR and I want to use brackets to group some expressions. My expression is the following :

eq('CodePropriete', 'MH')+AND+(gt('NbPiedsParcelle', '2')+OR+gt('NbRangsParcelle', '2'))+AND+eq('Cepage', 'Chardonnay')

I would expect this to be translated to (CodePropriete = MH) AND (NbPiedsParcelle > 2 OR NbRangsParcelle > 2) AND Cepage = Chardonnnay but my tests suggests it is translated to ((((CodePropriete = MH) AND NbPiedsParcelle > 2) OR NbRangsParcelle > 2) AND Cepage = Chardonnnay).

Am I doing something wrong ?

@alexmurari alexmurari added the enhancement New feature or request label Nov 3, 2023
@alexmurari
Copy link
Owner

Hi, @Yutsa.

This library does not support (yet) nested/grouped expressions and implementing this is not trivial. Unfortunatelly, I'm lacking time to maintain this lib for now, so it won't be implemented anytime soon.

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

No branches or pull requests

2 participants