The PostgreSQL docs are unfortunately scarce on JOINs http://www.postgresql.org/docs/8.4/static/tutorial-join.html I've never seen a JOIN producing several rows instead of columns before Michael suggested it in this thread -- Sent via pgsql-general mailing list (pgsql-general@xxxxxxxxxxxxxx) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-general