You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
It compiles in v2.0.1 but in v2.1.1 there is the compiler error:
error[E0277]: the trait bound `NullableExpression<measurement::columns::id>: Column` is not satisfied
--> src/main.rs:74:10
|
74 | .distinct_on(m::id.nullable())
| ^^^^^^^^^^^ the trait `Column` is not implemented for `NullableExpression<measurement::columns::id>`
|
So I tried to remove the nullable() so the two lines become:
Setup
Versions
Problem Description
Code using
fn distinct_on
works in Dieselv2.0.1
but not inv2.1.1
.Minimal reproducible example: https://gist.github.com/Ploppz/f8235d83f287bb7926655cd91dfba8fa
Cargo.toml
:diesel = { version = "=2.0.1", features = ["postgres", "r2d2"] }
It compiles in
v2.0.1
but inv2.1.1
there is the compiler error:So I tried to remove the
nullable()
so the two lines become:But then I get the error:
Which makes sense I guess, because the
measurement
table is left-joined som::id
is not always present.Checklist
closed if this is not the case)
The text was updated successfully, but these errors were encountered: