My colleague says they write MySQL, not SQL. How do you explain the difference, and does it change the SQL I write day to day?
SQL is the language: a published standard describing SELECT, INSERT, UPDATE, DELETE, CREATE TABLE and the rest, ratified by ISO and ANSI. MySQL is an engine: one particular implementation of that language, plus its own storage format, its own server process, its own replication and its own dialect quirks. People conflate them because MySQL is by far the most widely deployed engine, but Oracle, PostgreSQL, SQL Server, SQLite and MariaDB all speak SQL too, and their dialects diverge.
-- Portable ANSI SQL: this runs unchanged on MySQL, PostgreSQL, SQLite and SQL Server.
CREATE TABLE customers (
id INTEGER PRIMARY KEY,
name VARCHAR(120) NOT NULL
);
CREATE TABLE orders (
id INTEGER PRIMARY KEY,
customer_id INTEGER NOT NULL,
amount DECIMAL(10, 2) NOT NULL
);
INSERT INTO customers (id, name) VALUES (1, 'Ada Lovelace'), (2, 'Grace Hopper');
INSERT INTO orders (id, customer_id, amount) VALUES (1, 1, 120.00), (2, 1, 340.50), (3, 2, 75.25);
SELECT c.id, c.name, COUNT(o.id) AS order_count, ROUND(AVG(o.amount), 2) AS avg_order
FROM customers AS c
LEFT JOIN orders AS o ON o.customer_id = c.id
GROUP BY c.id, c.name
ORDER BY avg_order DESC NULLS LAST
LIMIT 10;Day to day, the difference rarely bites: joins, filters, aggregation, window functions and CTEs are essentially identical everywhere. It bites at the edges. MySQL wants backticks around identifiers (or double quotes in ANSI mode), implements UPSERT as ON DUPLICATE KEY UPDATE rather than the standard ON CONFLICT, and has no FETCH FIRST syntax — it uses LIMIT. PostgreSQL distinguishes types far more strictly and offers RETURNING on DML, which MySQL only added for some statements.
The practical advice: write ANSI SQL by default, learn the dialect of the engine you are actually deploying on, and never assume a query you wrote against SQLite will run unchanged on MySQL — that is where the real interview follow-up lives.