Skip to content
Topic

SQL

Master SQL and Databases fundamental to handles data for organizations to interpret and analyze data and make data easy to understand.

26 guides

SQL Window Functions: OVER and PARTITION BY SQL SQL Window Functions: OVER and PARTITION BY Learn SQL window functions in PostgreSQL: OVER, PARTITION BY, running sums with ORDER BY, where they run in a query, and the… November 17, 2026 · 12 min read
SQL Views: CREATE VIEW and Materialized Views in PostgreSQL SQL SQL Views: CREATE VIEW and Materialized Views in PostgreSQL Learn SQL views in PostgreSQL: CREATE VIEW, updatable views and CHECK OPTION, materialized views, REFRESH CONCURRENTLY with its unique index, and DROP… November 16, 2026 · 13 min read
SQL Recursive CTE: WITH RECURSIVE for Hierarchies, Trees and Date Series SQL SQL Recursive CTE: WITH RECURSIVE for Hierarchies, Trees and Date Series Learn the SQL recursive CTE (WITH RECURSIVE): walk a category tree with depth and path, build date series vs generate_series, and stop… November 15, 2026 · 14 min read
SQL CTE: WITH Clause and CTE vs Subquery SQL SQL CTE: WITH Clause and CTE vs Subquery Learn the SQL CTE (WITH clause) in PostgreSQL: chain several CTEs, rewrite nested subqueries, use MATERIALIZED in PostgreSQL 12+, and CTEs with… November 15, 2026 · 13 min read
SQL Subqueries: Scalar, IN, EXISTS and Correlated Subqueries SQL SQL Subqueries: Scalar, IN, EXISTS and Correlated Subqueries Learn SQL subqueries in PostgreSQL: scalar subqueries, IN and NOT IN, EXISTS, correlated subqueries and subqueries in FROM, with real results and… November 14, 2026 · 11 min read
SQL Transactions: BEGIN, COMMIT, ROLLBACK and SAVEPOINT SQL SQL Transactions: BEGIN, COMMIT, ROLLBACK and SAVEPOINT Learn SQL transactions in PostgreSQL: BEGIN, COMMIT, ROLLBACK and SAVEPOINT, autocommit in psql, ACID in plain words, and what an aborted transaction… November 13, 2026 · 12 min read
SQL Upsert: INSERT … ON CONFLICT and MERGE SQL SQL Upsert: INSERT … ON CONFLICT and MERGE Learn SQL upsert in PostgreSQL: INSERT ... ON CONFLICT DO NOTHING and DO UPDATE with EXCLUDED, why you need a unique constraint,… November 13, 2026 · 12 min read
SQL INSERT, UPDATE and DELETE: Change Data Safely with RETURNING SQL SQL INSERT, UPDATE and DELETE: Change Data Safely with RETURNING Learn SQL INSERT, UPDATE and DELETE in PostgreSQL: add rows, test the WHERE with SELECT first, use RETURNING, avoid changing every row,… November 12, 2026 · 11 min read
SQL CREATE TABLE: Data Types and Constraints SQL SQL CREATE TABLE: Data Types and Constraints Learn SQL CREATE TABLE in PostgreSQL: data types, PRIMARY KEY, FOREIGN KEY, UNIQUE, NOT NULL, CHECK, DEFAULT and IDENTITY, with the real… November 12, 2026 · 13 min read
SQL UNION vs UNION ALL, INTERSECT and EXCEPT SQL SQL UNION vs UNION ALL, INTERSECT and EXCEPT Learn SQL UNION vs UNION ALL, INTERSECT and EXCEPT with real examples: column rules, duplicates, ORDER BY, the errors you will see,… November 11, 2026 · 14 min read
SQL Self Join, CROSS JOIN, Semi-Joins and Anti-Joins SQL SQL Self Join, CROSS JOIN, Semi-Joins and Anti-Joins Learn the SQL self join, CROSS JOIN, semi-joins with EXISTS and anti-joins with NOT EXISTS, and see why NOT IN returns no… November 10, 2026 · 13 min read
SQL LEFT JOIN, RIGHT JOIN and FULL OUTER JOIN SQL SQL LEFT JOIN, RIGHT JOIN and FULL OUTER JOIN Learn SQL LEFT JOIN, RIGHT JOIN and FULL OUTER JOIN with real examples: keep unmatched rows, count them correctly, fix the ON… November 9, 2026 · 14 min read