Queries
A query is a SQL statement that asks for or changes data. The ones you must type without thinking: SELECT, INSERT, UPDATE, DELETE. Plus CREATE for structure. People also say ‘query’ only for SELECT — in a viva, say DML vs DDL if they split hairs.
SELECT reads. INSERT adds a row. UPDATE changes a row. DELETE removes a row. Always practise SELECT with the same WHERE before UPDATE/DELETE.
Read a query in this order in your head: FROM (which table) → WHERE (which rows) → SELECT (which columns). GROUP BY / HAVING / ORDER BY come after that story.
Trap — SELECT * in every answer. Name columns. Trap: UPDATE without WHERE — whole table becomes 0 marks.
On the example next to this theory: Queries: create two demo rows, then SELECT qty >= 2 ordered. Say which labels come back.
Name CRUD. Warn: no WHERE on UPDATE. Prefer listing columns.