37
Example:
create table foo(
id serial,
txt text
);
insert into foo(txt) values ('a'),('b'),('c') returning id;
Returns:
id
----
1
2
3
(3 rows)
It seems that the first id in the return value will always be the id for 'a', the second for 'b' and so on, but is this defined behaviour of insert into, or is it a coincidence that may fail under odd circumstances?