Comment

Comment by striking

I recently caught out someone trying to hide their deep knowledge of Postgres when, in a moment of weakness as I mentioned one of the benefits of TOAST, he replied "I guess that's why they call it 'the best thing since sliced bread'".

And that's when I knew.

Because that's an exact quote from the docs.

> This section provides an overview of TOAST (The Oversized-Attribute Storage Technique).

> PostgreSQL uses a fixed page size (commonly 8 kB), and does not allow tuples to span multiple pages. Therefore, it is not possible to store very large field values directly. To overcome this limitation, large field values are compressed and/or broken up into multiple physical rows. This happens transparently to the user, with only small impact on most of the backend code. The technique is affectionately known as TOAST (or “the best thing since sliced bread”). The TOAST infrastructure is also used to improve handling of large data values in-memory.

https://www.postgresql.org/docs/current/storage-toast.html

parent striking 4 years ago

Discussion

Live from the official Hacker News API

A modern reader for Hacker News · SvelteKit + Skeleton