Skip to content
Opensource internals
  • Posts

Postgres

PostgreSQL's timestamp and timestamptz Implementation in C

Oct 6, 2026 7 min read Jay Hubbert

Here is the punchline up front: in PostgreSQL, timestamp and timestamptz are the same value. Both are an 8-byte signed integer counting microseconds since 2000-01-01. The type …

PostgresInternalsTimestampTimestamptz

Read more →

PostgreSQL's bool Implementation in C

Oct 4, 2026 6 min read Jay Hubbert

bool looks like the easiest type in PostgreSQL. One bit of meaning, one byte of storage, done. It is not. The value has two different text spellings depending on which code path …

PostgresInternalsBool

Read more →

PostgreSQL Locks Buffers Without LWLocks

Oct 2, 2026 42 min read Jay Hubbert

Every time PostgreSQL reads a page it does two things: it pins the shared buffer that holds the page, and it takes a content lock on that buffer so that nobody rewrites the bytes …

PostgresPerformanceStorageConcurrencyInternals

Read more →

PostgreSQL's oid Implementation in C

Oct 1, 2026 6 min read Jay Hubbert

oid is the type of every system identifier in PostgreSQL: tables, indexes, functions, operators, types, namespaces. It looks like a narrower int4, and that is almost right. It is a …

PostgresInternalsOidOid8

Read more →

PostgreSQL's float4 and float8 Implementation in C

Sep 22, 2026 8 min read Jay Hubbert

float4 (SQL real) and float8 (SQL double precision) are the two IEEE-754 binary floating-point types. They are also the least mysterious types in PostgreSQL: a float4 really is the …

PostgresInternalsFloat4Float8

Read more →

← Newer Page 2 of 7 Older →

© 2026 Jay Hubbert · Built with Hugo 0.168.0

RSS ·