// Articles
Guides, tutorials, and comparisons to help you build better backend applications.
Integer minor units, numeric, or the money type: how each one stores currency amounts in Postgres, why floats are out, how to handle currencies with zero or three decimal places, and how to split amounts without losing a cent.
How INSERT ... ON CONFLICT works in Postgres, when to use DO NOTHING or DO UPDATE, how it compares to MERGE, and how to tell inserts from updates with RETURNING.
What a partial index is, the queries it speeds up, how partial unique indexes enforce rules like one active subscription per customer, and why prepared statements sometimes ignore them.
Postgres indexes the referenced side of a foreign key but not the referencing column. What that costs on deletes, updates and joins, how to find unindexed foreign keys, and when you can skip the index.
Store sensor readings in PostgreSQL and query them with TimescaleDB.