Re: Optimizing NOT IN plans / verify rewrite

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Kevin Grittner <Kgrittn@xxxxxxxxxxxx> wrote:
 
> Maybe before I get excited I should try it with a query which is
> actually logically equivalent.
 
Fixed version:
 
DELETE FROM foo
  where type = 'o' and foo.b in (
  select b from foo WHERE type = 'o'
  except SELECT b FROM bar
  except SELECT b FROM foo where type <> 'o');
 
The change didn't affect run time significantly; it still beats the
others.
 
-Kevin


-- 
Sent via pgsql-performance mailing list (pgsql-performance@xxxxxxxxxxxxxx)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-performance


[Postgresql General]     [Postgresql PHP]     [PHP Users]     [PHP Home]     [PHP on Windows]     [Kernel Newbies]     [PHP Classes]     [PHP Books]     [PHP Databases]     [Yosemite]

  Powered by Linux