Every SQL cheat sheet in one place - core window functions, platform-specific syntax (Snowflake, Databricks), and SQL interview prep. Each sheet is runnable, snippet-heavy, and updated for 2026.
These are not generic "SQL 101" dumps. They are the patterns that show up in production reviews: QUALIFY after a window function on Snowflake, MERGE for slowly changing dimensions, VARIANT flattening, and the frame-clause mistakes that silently double-count a running total. If you already write Postgres, start with the Snowflake SQL sheet and note TIMESTAMP_NTZ, QUALIFY, and ZEROIFNULL. If you are prepping interviews, do the window-function sheet twice — most take-home failures are RANK vs DENSE_RANK and an unbounded frame.
Pair the sheets with the SQL formatter and the in-browser SQL playground so you can paste an example, change the frame, and see the result without standing up a warehouse.
When a query is slow, the first three checks are the same on every warehouse: is the filter on a column the storage layer can prune, is the join exploding the grain, and is a window running over an unbounded frame. Snowflake adds QUALIFY, result cache, and warehouse size. Databricks adds Photon and Delta clustering. Postgres habits (lots of indexes, sequential CTEs) do not transfer one-for-one.
Interview SQL on this site is worked, not dumped. If you cannot explain why the wrong option is wrong, you are not ready for a live round. Use the window-function sheet, then the interview sheet, then the playground — in that order.
Use the SQL formatter to pretty-print queries and the JSON-to-SQL converter to generate CREATE TABLE DDL.
Explore cloud platform cheat sheets, orchestration, and the full cheat sheet library.
← Back to Home