Open mhriemers opened 7 months ago
This is my first comment. I'm sorry if I can't be clear. I think the solution might be to first filter and group the remaining people according to their surnames.
val q = quote {
query[Person]
.filter(_.firstName != lift("John"))
.groupBy(_.lastName)
.map { case (lastName, people) =>
(lastName,people.size,people.map(_.age).sum)
}
}
//SELECT x1.last_name, COUNT(*), SUM(x1.age) FROM person x1 WHERE x1.first_name <> ? GROUP BY x1.last_name
Version:
4.8.0
Module:quill-jdbc-zio
Database:postgresql
Expected behavior
Actual behavior
Steps to reproduce the behavior
https://scastie.scala-lang.org/9aFplZTKSQ6KO1WEOC1a9A
Workaround
@getquill/maintainers