Skip to main content

12 posts tagged with "performance"

View All Tags

AI-assisted Postgres experiment: number of partitions vs. planning time

· 9 min read
Nikolay Samokhvalov

In one of the recent PostgresFM[1] episodes, Michael Christofides and Nikolay discussed planning time and what can affect it. One of the obvious negative factors we've discussed is the large number of partitions a partition table might have.

In this post, we're using our Postgres.AI assistant[2] to see how planning time depends on the number of partitions.

This is the very first blog post of its kind: it has an integrated AI that you can use to explore the topic discussed here further, to repeat the experiment, alter it in any direction, and study the Postgres behavior more effectively.

Links

  1. [1] PostgresFM https://postgres.fm/
  2. [2] Postgres.AI assistant https://postgres.ai/blog/20240127-postgres-ai-bot

How partial, covering, and multicolumn indexes may slow down UPDATEs in PostgreSQL

· 15 min read
Nikolay Samokhvalov

Based on a true story.

This article was originally published in 2018[1]. This is a reviewed and extended version of it. The discussed findings can be applied to any actual major version of PostgreSQL.

Primum non nocere​

"Primum non nocere" – this is a fundamental principle that is well-known to anyone working in healthcare: "first, do no harm". It is a reminder: when considering any action that is supposed to improve something, we always need to look at the global picture to see if there might be something else that be damaged by the same action.

This is a great principle and it is used not only in healthcare, of course. I strongly believe that it has to be used in database optimization too, and we need better tools to make it happen.

Links

  1. [1] in 2018 https://medium.com/@samokhvalov/how-partial-indexes-affect-update-performance-in-postgres-d05e0052abc