Count in relational queries

BQBernardo Quina5/23/2023
How do I count in relational queries? For example if i'm querying db.query.posts.findMany() and want to include an extra field that counts the number of likes (diff table), how can I achieve that? Couldn't make it work with the "extras" and trying to make a sqlcount() there.

Thanks in advance
Bbloberenober6/2/2023
aggregations are not supported yet, but it's one of our priorities