Common Table Expression (CTE) aka WITH clause
Window Function - an old SQL standard that is now available in MySQL
Extract JSON elements from a JSON column (MariaDB, MySQL)
Create a json object from your table columns
Not equal where condition on index as a performance problem
SQL Row-Value constructor in a Where-clause
Prevent a temporary DB table caused by SQL group by
Doing math in SQL can ignore indices
Even LIKE can use an index in SQL. It depends on the wildcard.
Combined indexes may not work with OR. Try an index_merge in MySQL
How to make MySQL using an index only by adding "order by"
Instead of MySQL's IFNULL function, this works on PostgreSQL, Sqlite and others too
Getting row counts of different columns in one query in MySQL