pg.ddx.io  pgsql-bugs@postgresql.org mailing list archive  
help / color / mirror / Atom feed
BUG #6490: Not checking column existence in sub query
2+ messages / 2 participants
[nested] [flat]

* BUG #6490: Not checking column existence in sub query
@ 2012-02-27 11:39 anisimovt@gmail.com
  2012-02-27 14:26 ` Re: BUG #6490: Not checking column existence in sub query hubert depesz lubaczewski <depesz@depesz.com>
  0 siblings, 1 reply; 2+ messages in thread

From: anisimovt@gmail.com @ 2012-02-27 11:39 UTC (permalink / raw)
  To: pgsql-bugs

The following bug has been logged on the website:

Bug reference:      6490
Logged by:          Timofey Anisimov
Email address:      anisimovt@gmail.com
PostgreSQL version: 9.1.2
Operating system:   Linux 
Description:        

SELECT * FROM table1 where col1 in (select col2 from table2)

if col2 exist in table1 and not exist in table2 there will be no error and
query output all rows from table1;




^ permalink  raw  reply  [nested|flat] 2+ messages in thread

* Re: BUG #6490: Not checking column existence in sub query
  2012-02-27 11:39 BUG #6490: Not checking column existence in sub query anisimovt@gmail.com
@ 2012-02-27 14:26 ` hubert depesz lubaczewski <depesz@depesz.com>
  0 siblings, 0 replies; 2+ messages in thread

From: hubert depesz lubaczewski @ 2012-02-27 14:26 UTC (permalink / raw)
  To: anisimovt@gmail.com; +Cc: pgsql-bugs

On Mon, Feb 27, 2012 at 11:39:55AM +0000, anisimovt@gmail.com wrote:
> The following bug has been logged on the website:
> 
> Bug reference:      6490
> Logged by:          Timofey Anisimov
> Email address:      anisimovt@gmail.com
> PostgreSQL version: 9.1.2
> Operating system:   Linux 
> Description:        
> 
> SELECT * FROM table1 where col1 in (select col2 from table2)
> 
> if col2 exist in table1 and not exist in table2 there will be no error and
> query output all rows from table1;

sure. it is so called "correlated subquery" and it's definitely not
a bug.

Best regards,

depesz

-- 
The best thing about modern society is how easy it is to avoid contact with it.
                                                             http://depesz.com/



^ permalink  raw  reply  [nested|flat] 2+ messages in thread


end of thread, other threads:[~2012-02-27 14:26 UTC | newest]

Thread overview: 2+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2012-02-27 11:39 BUG #6490: Not checking column existence in sub query anisimovt@gmail.com
2012-02-27 14:26 ` hubert depesz lubaczewski <depesz@depesz.com>

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox