Disclosure

Disclosure

Transparency about links and funding, per FTC guidance.

This site is free. Some outbound links — for example to data tools, warehouses, or hosting providers — may be affiliate links: if you sign up through them we may earn a commission at no extra cost to you. We only link to tools we'd actually use, and a commission never changes what we recommend.

The databases these recipes cover (PostgreSQL, MySQL, SQLite, DuckDB and the BigQuery/Snowflake SQL dialects) are independent products of their respective owners; this site is an unaffiliated community reference.

No warranty. These queries are provided as-is. Date logic is subtle — argument order, boundary counting, and time zones all change results — so test a recipe against your own data (and your engine's exact version) before relying on it in production.