X-Original-To: pgsql-performance-postgresql.org@localhost.postgresql.org Received: from localhost (unknown [200.46.204.2]) by svr1.postgresql.org (Postfix) with ESMTP id B646DD1BA2E for ; Wed, 10 Mar 2004 08:13:45 +0000 (GMT) Received: from svr1.postgresql.org ([200.46.204.71]) by localhost (neptune.hub.org [200.46.204.2]) (amavisd-new, port 10024) with ESMTP id 96951-02 for ; Wed, 10 Mar 2004 04:13:39 -0400 (AST) Received: from expasy-ng.isb-sib.ch (expasy-f.unige.ch [192.33.215.142]) by svr1.postgresql.org (Postfix) with ESMTP id 90E8FD1B979 for ; Wed, 10 Mar 2004 04:13:36 -0400 (AST) Received: from caliente (router.isb-sib.ch [192.33.215.254]) (authenticated bits=0) by expasy-ng.isb-sib.ch (8.12.10/8.12.8) with ESMTP id i2A8DXki019795 for ; Wed, 10 Mar 2004 09:13:33 +0100 Message-ID: <001401c40677$9723fed0$c300000a@caliente> From: "Eric Jain" To: "pgsql-performance" References: <62371.200.174.148.100.1078889715.squirrel@webmail.webnow.com.br> Subject: Re: optimizing large query with IN (...) Date: Wed, 10 Mar 2004 09:13:37 +0100 Organization: Swiss Institute of Bioinformatics MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit X-Priority: 3 X-MSMail-Priority: Normal X-Mailer: Microsoft Outlook Express 6.00.2800.1158 X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1165 X-sib-MailScanner-Information: Please contact the ISP for more information X-sib-MailScanner: Found to be clean X-Virus-Scanned: by amavisd-new at postgresql.org X-Archive-Number: 200403/126 X-Sequence-Number: 5982 > UPDATE table SET table.par = table.par + 1 > WHERE table.key IN ('value1', 'value2', ... , 'value1200' ) How fast is the query alone, i.e. SELECT * FROM table WHERE table.key IN ('value1', 'value2', ... , 'value1200' )