Skip site navigation (1) Skip section navigation (2)

Re: Quick question

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Christopher Kings-Lynne <chriskl(at)familyhealth(dot)com(dot)au>
Cc: Hackers <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: Quick question
Date: 2003-10-03 13:59:34
Message-ID: (view raw, whole thread or download thread mbox)
Lists: pgsql-hackers
Christopher Kings-Lynne <chriskl(at)familyhealth(dot)com(dot)au> writes:
> If someone could help me with this, it would be cool.  How do I query 
> the catalogs to find the underlying index for a constraint?  (Assuming 
> the constraint is primary or unique)

A first approximation is that the constraint and the index have the same
name, but I suppose someone could break that association by renaming the
index.  Look in pg_depend for an internal dependency entry from the
index to the constraint if you want to be sure.

			regards, tom lane

In response to


pgsql-hackers by date

Next:From: Patrick WelcheDate: 2003-10-03 14:00:36
Subject: Re: ecpg doesn't compile (datetime.h/dtime_t)
Previous:From: Bruno Wolff IIIDate: 2003-10-03 13:57:49
Subject: timestamp.c is broken (probably by ecpg) in 7.4

Privacy Policy | About PostgreSQL
Copyright © 1996-2018 The PostgreSQL Global Development Group