Answers for "how to return record on insert in postgresql"

SQL
6

return insert results in POSTGRESQL

# to select specific columns
INSERT INTO users (firstname, lastname) VALUES ('Joe', 'Cool') RETURNING id, firstname;
# to return every column
INSERT INTO users (firstname, lastname) VALUES ('Joe', 'Cool') RETURNING *;
Posted by: Guest on June-11-2020

Code answers related to "how to return record on insert in postgresql"

Code answers related to "SQL"

Browse Popular Code Answers by Language