Re: Notice about costly ri checks

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Fabien COELHO <coelho(at)cri(dot)ensmp(dot)fr>
Cc: PostgreSQL Patches <pgsql-patches(at)postgresql(dot)org>
Subject: Re: Notice about costly ri checks
Date: 2004-03-03 14:58:39
Message-ID: 12738.1078325919@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-patches

Fabien COELHO <coelho(at)cri(dot)ensmp(dot)fr> writes:
> This patch adds a "notice" at constraint creation time if the referential
> integrity check is to be "costly", that is the comparison operator
> involves some coercion.

This is not the correct test at all. The correct test would involve
looking in pg_amop to see if the selected operator is a member of the
opclass for the referenced column's index. (IIRC there are helper
functions in lsyscache.c that will make this easier.)

regards, tom lane

In response to

Responses

Browse pgsql-patches by date

  From Date Subject
Next Message Fabien COELHO 2004-03-03 15:26:48 Re: Notice about costly ri checks
Previous Message Bruce Momjian 2004-03-03 14:24:10 Fix usage string for oid2name