Task: Use INSERT...RETURNING Value in Another INSERT in PostgreSQL
Task: Use INSERT...RETURNING Value in Another INSERT in PostgreSQL: a task in Terminal-Lego-15k (Harbor dataset). In PostgreSQL, you need to demonstrate how to use the return value of an INSERT...RETURNING clause as input for another INSERT statement. This is useful when inserting a row into one…
The task
In PostgreSQL, you need to demonstrate how to use the return value of an `INSERT...RETURNING` clause as input for another `INSERT` statement. This is useful when inserting a row into one table and immediately using its generated ID as a foreign key reference in a second table.
Part of PrimeIntellect/Terminal-Lego-15k.