Hello all! Would anyone happen to know if <filtere...
# orm-help
a
Hello all! Would anyone happen to know if filtered count is supported within relation counts? Doing it the following way results in an error:
Copy code
const usersWithCount = await prisma.user.findMany({
  include: {
    _count: {
      select: { posts: {where: {approved: true}} },
    },
  },
})