PostgreSQL "RETURNING"
Today I learned that PostgreSQL INSERT/UPDATE/DELETE has a RETURNING clause that returns the computed values.
We can use it to get values that are generated by database such as sequences or defaults.
Check this out:
h/t @joshuadavey
Tweet