I'd like to get the dataset of number of user's signed on each day.
I don't think groupBy works on created_at because the created_at stores timestamp
I found a query that looks like this
Copy code
SELECT SUM(foo), DATE(created_at) DateOnly FROM users GROUP BY DateOnly;
Is there a way to do this without raw query using prisma?
✅ 1
n
Nurul
08/04/2022, 6:35 AM
Hi Sagar 👋
For now, raw query would be the recommended way. We do have a Feature Request: #6653 to support GroupBy over date ranges.
Please feel free to add a 👍 to the Feature Request so that we could prioritise it.