pg.ddx.io  pgsql-sql@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Frank Joerdens <frank@joerdens.de>
To: pgsql-sql@postgresql.org
Subject: displaying constraints
Date: Wed, 14 Feb 2001 14:01:09 +0100
Message-ID: <20010214140109.A19494@rakete.joerdens.de> (raw)

The only what that I am aware of in which you can display the
constraints that have been created for a table is by dumping out the
schema with the -s option and then trying to reconstruct the foreign key
references from the <unnamed> triggers which where created by the e.g.

some_column	int4 references other_table ( other_column ),

statements in the queries which created the database or table. This is
considerably harder than just looking at the sql which created the
table, as I am just figuring out the hard way. I'll be recreating my
entire database from .sql files in order to have a proper documentation
as to the database structure. I'd rather not, but it seems just plain
too difficult to reconstruct everything that I did via alter table . . .
I am not really certain whether I can exactly reverse-engineer all the
foreign keys from the triggers.

Is there a better solution to my problem?

Cheers, Frank



Message-ID: <20010214140109.A19494@rakete.joerdens.de>
Permalink:  ../20010214140109.A19494@rakete.joerdens.de/
Also on:    postgresql.org/message-id/20010214140109.A19494@rakete.joerdens.de

 · 

reply

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 from your mail client; the link fills in
  the headers below: reply via email
  Some clients, webmail especially, drop In-Reply-To and References from
  a link, and the reply then starts a new thread: use the mbox below.

  To: pgsql-sql@postgresql.org
  Cc: frank@joerdens.de
  Subject: Re: displaying constraints
  In-Reply-To: <20010214140109.A19494@rakete.joerdens.de>
  References: <20010214140109.A19494@rakete.joerdens.de>

* 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