From: Tom Lane <tgl@sss.pgh.pa.us>
To: postgresql-ctennant@elirious.com
Cc: pgsql-sql@postgresql.org
Subject: Re: planner used functional index in 7.3.6, now does a seq scan in 7.4.7 after upgrade
Date: Sun, 19 Nov 2006 02:28:01 -0500
Message-ID: <6251.1163921281@sss.pgh.pa.us> (raw)
In-Reply-To: <455FF56D.7030001@elirious.com>
References: <455FF56D.7030001@elirious.com>
Chris Tennant <postgresql-ctennant@elirious.com> writes:
> here's the definition of the function (as immutable):
> CREATE OR REPLACE FUNCTION stereo_id (INTEGER, INTEGER, INTEGER) RETURNS
> INTEGER AS
> 'BEGIN RETURN CASE WHEN $2 = $3 THEN $1 ELSE -1 END; END;'
> LANGUAGE 'plpgsql' IMMUTABLE;
> and here's the original definition of the functional index:
> CREATE INDEX stereo_pair_image_attributes_stereo_id
> ON opt_stereo_pair_image_attributes
> (stereo_id(right_patient_data_id,left_patient_data_id));
Um, that index seems to be on some other function that may have the same
name, but only takes two arguments?
regards, tom lane
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients using the --to and --cc options:
reply via email
To: pgsql-sql@postgresql.org
Cc: tgl@sss.pgh.pa.us, postgresql-ctennant@elirious.com
Subject: Re: planner used functional index in 7.3.6, now does a seq scan in 7.4.7 after upgrade
In-Reply-To: <6251.1163921281@sss.pgh.pa.us>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
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