SQL Mastery, Discovery & Nuances

The ultimate SQL reference with examples and database compatibility.

SQL Master, Discovery & Nuances (SQL MDN) Docs is the ultimate documentation of SQL keywords, operators, clauses, statements and functions.

The key SQL MDN Docs feature is database compatibility. There’re so many relational databases nowadays (MySQL, PostgreSQL, SQLite, AWS Redshift, Google Cloud, Snowflake, etc) and they’re keep coming!

SQL has a slightly different syntax in all databases. The SQL MDN Docs are built to help you bridge that syntax gap. If you know how to do something in one database, SQL MDN Docs will give you a recipe on how to do the same in another database.

License

SQL MDN Docs were kicked of in the early 2024, so new pages are coming every week. It’s worth mention that SQL MDN Docs is an open-source project. All pages, including the code samples, are available under the CC BY-NC-SA 4.0 license.

Get involved

The entire source code of all SQL MDN Docs is available on Github.

Join the project: create a new page or expand existing documentation. Check out contribution guidelines.

SQL MDN Docs

Conditional functions

COALESCE NULLIF

Date functions

current_date

Window functions

LAG LEAD SUM