Received: from taru.tm.ee (unknown [213.180.2.168]) by postgresql.org (Postfix) with ESMTP id 794CE475A1B for ; Thu, 11 Jul 2002 15:49:25 -0400 (EDT) Received: (from hannu@localhost) by taru.tm.ee (8.11.6/8.11.6) id g6BKp4n18775; Thu, 11 Jul 2002 22:51:04 +0200 X-Authentication-Warning: taru.tm.ee: hannu set sender to hannu@tm.ee using -f Subject: Re: please help on query From: Hannu Krosing To: Luis Alberto Amigo Navarro Cc: pgsql-hackers@postgresql.org In-Reply-To: <005e01c228ee$bd1913e0$cab990c1@atc.unican.es> References: <005e01c228ee$bd1913e0$cab990c1@atc.unican.es> Content-Type: text/plain Content-Transfer-Encoding: 7bit X-Mailer: Ximian Evolution 1.0.3.99 Date: 11 Jul 2002 22:51:04 +0200 Message-Id: <1026420664.18193.21.camel@taru.tm.ee> Mime-Version: 1.0 X-Archive-Number: 200207/469 X-Sequence-Number: 24843 On Thu, 2002-07-11 at 17:22, Luis Alberto Amigo Navarro wrote: > I can't improve performance on this query: You may also want to rewrite lineitem.shipdate<(('1994-01-01')::DATE+('1 year')::INTERVAL)::DATE into lineitem.shipdate<(('1995-01-01')::DATE if you can, as probably the optimiser will not recognize it else as a constant and won't use index on lineitem.shipdate. ---------------- Hannu