MySQL equivalent of PostgreSQL VALUES statement?

In PostgreSQL, we have a VALUES statement .

For instance,

VALUES (1, 'one'), (2, 'two'), (3, 'three');

equivalently

SELECT 1 AS column1, 'one' AS column2
UNION ALL
SELECT 2, 'two'
UNION ALL
SELECT 3, 'three';

What is the analogue in MySQL?

+3
source share
1 answer

MySQL does not support row constructor (standard) using VALUES. It is supported for an INSERT statement, but is never a "standalone" statement.

+1
source

All Articles