Big data statistics
Hi there,
I’m building an app that gonna saves games played by players on a competitive game.
I tried to make some statements about how much games should we expect to save each day.
I found something around 1.000 / day
I never manipulated this amount of data before, and I’ll need to make stats on it. Like average dps for a specific hero, average deaths etc.
I was wondering if prisms give tools to compute this kind of statistics ? And what about partitioning the table, for each months or something like that, is there some tools for that ?
I’m pretty novice with database manipulations. I always made basic features that doesn’t raise those kind of questions, so I’m a bit lost here 😁
Note that I’m using prisma with Postgres, self-hosted, running with a fastify server
2 Replies
You selected to wait for the human sages. They'll share their wisdom soon.
Grab some tea while you wait, or check out
#ask-ai if you'd like a quick chat with the bot anyway!Prisma Client supports a range of aggregation queries out of the box, which are perfect for generating statistics like averages, sums, minimums, maximums, and counts.
https://www.prisma.io/docs/orm/prisma-client/queries/aggregation-grouping-summarizing
Aggregation, grouping, and summarizing (Concepts) | Prisma Document...
Use Prisma Client to aggregate, group by, count, and select distinct.