Re: how to determine array size

From: Rod Taylor <rbt(at)rbt(dot)ca>
To: Forest Wilkinson <lyris-pg(at)tibit(dot)com>
Cc: pgsql-sql(at)postgresql(dot)org
Subject: Re: how to determine array size
Date: 2003-06-10 12:04:27
Message-ID: 1055246667.56597.39.camel@jester
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-sql

On Mon, 2003-06-09 at 16:23, Forest Wilkinson wrote:
> I need to enumerate the constraints on any given column in a table, so
> I'm examining pg_constraint to get the relevant information. The
> conkey array contains a list of constrained columns, and although I am
> able to check conkey[1] for constraints on a single column, I would
> like to properly handle multi-column constraints.

You may have an easier time dealing with pg_get_constraintdef() than
trying to get the info from the source.

The above function outputs the necessary SQL to rebuild the constraint,
and is used by pg_dump.

--
Rod Taylor <rbt(at)rbt(dot)ca>

PGP Key: http://www.rbt.ca/rbtpub.asc

In response to

Responses

Browse pgsql-sql by date

  From Date Subject
Next Message Achilleus Mantzios 2003-06-10 12:32:00 Re: how to determine array size
Previous Message Rod Taylor 2003-06-10 11:57:10 Re: Coalesce/Join/Entries may not exist.