Re: Why *no* ambig·uous complain in select part?

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: emilu(at)encs(dot)concordia(dot)ca
Cc: pgsql-sql(at)postgresql(dot)org
Subject: Re: Why *no* ambig·uous complain in select part?
Date: 2008-08-22 22:41:30
Message-ID: 19969.1219444890@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-sql

Emi Lu <emilu(at)encs(dot)concordia(dot)ca> writes:
> Just notice one small thing, and need your information about select

> select col1, col2
> from table1
> left join table2
> using (col1, col2)
> ;

> This query never complain about ambiguous columns of col1 and col2 in
> the select part.

That's because you used USING, which merges the similarly-named columns
into just one output column. RTFM, or any SQL book.

regards, tom lane

In response to

Browse pgsql-sql by date

  From Date Subject
Next Message Lew 2008-08-22 23:39:46 Re: Regarding access to a user
Previous Message Mark Roberts 2008-08-22 21:33:59 Re: RE: [SQL] Why *no* ambig.uous complain in select part?