-
-
Notifications
You must be signed in to change notification settings - Fork 1.1k
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
add some multirange operations support #4261
add some multirange operations support #4261
Conversation
0fda44e
to
8430246
Compare
Hi @weiznich, sorry for keeping this PR open for so long. I want to write something like 063297d |
No worries for taking some time on this.
It's a good idea to skip the table setup as that should make the tests easier. As for the problem: I think something like this should work: diesel::select((1..5).into_sql::<Range<Integer>>().contains(4)).load::<bool>(conn).unwrap(); The |
063297d
to
34a2c95
Compare
b6b3277
to
7de39ed
Compare
Hi @weiznich, thanks for the patient. I think it adds a test to all the new behavior. diesel/diesel/src/pg/expression/expression_methods.rs Lines 950 to 956 in 381be19
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good, thanks 🙏
Technically this should be possible by introducing another generic parameter on the function signature above. The |
Thanks so much for the explanation. Can we merge this PR? |
I will do that as soon as I fixed the CI. That turns out to be more problematic this time for whatever reason :( |
Oh thanks! |
Add multirange contains support under #4240
It is a small test to check the format before moving everything else