kurtbuilds / ormlite

An ORM in Rust for developers that love SQL.
https://crates.io/crates/ormlite
MIT License
216 stars 11 forks source link

Join error using a bool field #20

Closed gmLucario closed 1 year ago

gmLucario commented 1 year ago

if i use the Join example and a bool field is added Organization the next error is shown:

error[E0271]: type mismatch resolving `<R as Row>::Database == Sqlite`
 --> src/models/person.rs:6:10
  |
6 | #[derive(Model, Debug)]
  |          ^^^^^ expected associated type, found struct `Sqlite`
  |
  = note: expected associated type `<R as Row>::Database`
                      found struct `Sqlite`
  = help: consider constraining the associated type `<R as Row>::Database` to `Sqlite` or calling a method that returns `<R as Row>::Database`
  = note: for more information, visit https://doc.rust-lang.org/book/ch19-03-advanced-traits.html
  = note: this error originates in the derive macro `Model` (in Nightly builds, run with -Z macro-backtrace for more info)

i share the zip code: Archive.zip

kurtbuilds commented 1 year ago

Thank you for reporting this!

Fixed with regression test (based on your provided project) in 0.11.