Re: BUG #7653: Minor problem with join condition

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: stefano(at)sportilia(dot)com
Cc: pgsql-bugs(at)postgresql(dot)org
Subject: Re: BUG #7653: Minor problem with join condition
Date: 2012-11-12 14:30:03
Message-ID: 13179.1352730603@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-bugs

stefano(at)sportilia(dot)com writes:
> Don't know if this is a bug or a correct behaviour, but in a query like
> this:

> SELECT t1.* FROM
> table1 t1 JOIN
> table2 t2 ON t1.id = t2.t1id JOIN
> table3 t3 ON t1.id = t2.t1id

> The parser should return an error because we are joining a table without
> using any of its column.

There is no such restriction in the SQL standard.

regards, tom lane

In response to

Browse pgsql-bugs by date

  From Date Subject
Next Message Fujii Masao 2012-11-12 14:53:58 Re: [BUGS] BUG #7534: walreceiver takes long time to detect n/w breakdown
Previous Message stefano 2012-11-12 10:14:49 BUG #7653: Minor problem with join condition