3 ms·
I have seen this recommendation many times in PostgreSQL circles (well, I've also seen it sometimes in general SQL circles, but it is much rarer) due to Postgre
by saurik 13y ago
I have seen this recommendation many times in PostgreSQL circles (well, I've also seen it sometimes in general SQL circles, but it is much rarer) due to PostgreSQL being an OODBMS: "tables" are just "types" in PostgreSQL, which with plural table names leads to awkward situations where you might be casting a value--a value that represents a single user--to the type "users". Or you write a function that returns a single user: it is confusing to have the return type of that function be "users". The "setof" type operator also makes a little more sense if the type argument is singular.