Skip to main content
Journey Uncommon Logo
JourneyUncommon
mediumSQLCTEs WITHSingle-choice MCQ

What does this data-modifying CTE statement return and do?

WITH moved AS ( DELETE FROM staging WHERE processed = true RETURNING * ) INSERT INTO archive SELECT * FROM moved;