You can calculate multiple aggregates in a single database query

You can calculate multiple aggregates in a single database query

⚡️ Database Tip

You don't have to execute multiple queries to calculate different aggregates. With the filter clause you can narrow the rows which should be included for the calculation. So you may need to scan the table only once, the performance impact can be massive 🔥

We're writing a book, you can get it for free here.