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

Combined AND and OR predicate in Criteria Builder #267

Closed
IvanKonevJr opened this issue Jan 3, 2020 · 1 comment
Closed

Combined AND and OR predicate in Criteria Builder #267

IvanKonevJr opened this issue Jan 3, 2020 · 1 comment
Labels
type: enhancement A general enhancement

Comments

@IvanKonevJr
Copy link

IvanKonevJr commented Jan 3, 2020

For example:
Criteria.where(column1).is(value1).and(column2).is(value2).or(column3).is(value3)

return SQL: where column1=value1 and column2=value2 or column3=value3

Needed grouping Criteria:
where column1=value1 and (column2=value2 or column3=value3)

may be this way?:
val orCriteria = Criteria.groupStep(column2).is(value2).or(column3).is(value3) Criteria.where(column1).is(value1).and(orCriteria)`

then OR and AND overloaded by CriteriaGroup type

@mp911de mp911de added the type: enhancement A general enhancement label Feb 3, 2020
@mp911de mp911de added this to the 1.1 M3 (Neumann) milestone Feb 3, 2020
@mp911de
Copy link
Member

mp911de commented Feb 18, 2020

The issue is going to be addressed with #289 / #307.

@mp911de mp911de closed this as completed Mar 31, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type: enhancement A general enhancement
Projects
None yet
Development

No branches or pull requests

2 participants