Re: [GENERAL] How to handle results with column names clash

2010-09-28 Thread Darren Duncan
Darren Duncan wrote: 3. Suggestion, but it would be probably hard to implement: to make SQL engine prefix each returned column with table alias. Of course it would not be a default behavior, but it would be enabled by some session wide setting. # SELECT * FROM c1, c2 WHERE c1.id=c2.id; c1.id |

Re: [GENERAL] How to handle results with column names clash

2010-09-28 Thread Darren Duncan
Bartlomiej Korupczynski wrote: I'm curious how do you handle results from multiple tables with repeated column names. For example: # CREATE TABLE c1 (id integer PRIMARY KEY, address inet); # CREATE TABLE c2 (id integer PRIMARY KEY, address text); # SELECT * FROM c1 JOIN c2 USING (id); id | addr

Re: [GENERAL] How to handle results with column names clash

2010-09-28 Thread Raymond O'Donnell
On 28/09/2010 23:53, Bartlomiej Korupczynski wrote: Hi, I'm curious how do you handle results from multiple tables with repeated column names. For example: # CREATE TABLE c1 (id integer PRIMARY KEY, address inet); # CREATE TABLE c2 (id integer PRIMARY KEY, address text); # SELECT * FROM c1 JOIN