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 C5A16D1B530 for ; Wed, 10 Mar 2004 08:32:58 +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 99239-03 for ; Wed, 10 Mar 2004 04:32:50 -0400 (AST) Received: from houston.familyhealth.com.au (fhnet.arach.net.au [203.22.197.21]) by svr1.postgresql.org (Postfix) with ESMTP id 82305D1B4DB for ; Wed, 10 Mar 2004 04:32:47 -0400 (AST) Received: from familyhealth.com.au (work-40.internal [192.168.0.40]) by houston.familyhealth.com.au (8.12.9p1/8.12.9) with ESMTP id i2A8WbWL095245; Wed, 10 Mar 2004 16:32:37 +0800 (WST) (envelope-from chriskl@familyhealth.com.au) Message-ID: <404ED40F.2040800@familyhealth.com.au> Date: Wed, 10 Mar 2004 16:38:39 +0800 From: Christopher Kings-Lynne User-Agent: Mozilla Thunderbird 0.5 (Windows/20040207) X-Accept-Language: en-us, en MIME-Version: 1.0 To: Eric Jain Cc: pgsql-performance Subject: Re: optimizing large query with IN (...) References: <62371.200.174.148.100.1078889715.squirrel@webmail.webnow.com.br> <001401c40677$9723fed0$c300000a@caliente> In-Reply-To: <001401c40677$9723fed0$c300000a@caliente> Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit X-Virus-Scanned: by amavisd-new at postgresql.org X-Archive-Number: 200403/127 X-Sequence-Number: 5983 >>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' ) Also, post the output of '\d table' and EXPLAIN ANALYZE UPDATE... Chris