Question: In recent versions of MySQL (8.0+), what's the correct syntax to declare a CTE (Common Table Expression)?
- WITH (SELECT id FROM users) as cte, SELECT ...
- WITH (SELECT id FROM users) as cte SELECT ...
- WITH cte as (SELECT id FROM users), SELECT ...
- WITH cte as (SELECT id FROM users) SELECT ...
Answer: The correct answer of the above question is Option D:WITH cte as (SELECT id FROM users) SELECT ...