aboutsummaryrefslogtreecommitdiff
path: root/content/posts/postgres-aggregates-correction
diff options
context:
space:
mode:
authorMartin Kagamino Lehoux <martin@lehoux.net>2026-03-29 16:34:08 +0200
committerMartin Kagamino Lehoux <martin@lehoux.net>2026-03-29 16:34:08 +0200
commit722c30f3f4bf356403c49e77385aaf16e7407e49 (patch)
tree52cc3a68a32e20f50cb32d29e07172dc6d8c065f /content/posts/postgres-aggregates-correction
parent99cf41d65e3d78137c3d71f8d7587c52a1735727 (diff)
Improved sections
Diffstat (limited to 'content/posts/postgres-aggregates-correction')
-rw-r--r--content/posts/postgres-aggregates-correction/index.md12
1 files changed, 2 insertions, 10 deletions
diff --git a/content/posts/postgres-aggregates-correction/index.md b/content/posts/postgres-aggregates-correction/index.md
index 180229f..d94fcac 100644
--- a/content/posts/postgres-aggregates-correction/index.md
+++ b/content/posts/postgres-aggregates-correction/index.md
@@ -111,15 +111,7 @@ FROM products;
| Subquery `count(*)` | Index Only Scan | 100ms |
| Merged CTEs | Parallel Seq Scan | 100ms |
-## Going further
-
-I have mixed feelings about this updated version. When I discovered
-this, I thought the whole point of my article collapsed. But now
-that I did the work to show it, I'm not so sure. Here are some
-updated limitations to the use of subqueries.
-
-
-### Leaf filtering
+## Leaf filtering
The Subquery approach is better for root table filtering. If you
want to compute the same statistics, but only for products with
@@ -222,7 +214,7 @@ LEFT JOIN product_orders ON products.id = product_orders.product_id;
| Subquery `count(*)` | 100ms | 110ms |
| Merged CTEs | 100ms | 140ms |
-### Disk usage
+## Disk usage
Another important aspect is disk usage. Here's a summary of disk
read for each query.