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

Peripheral Links

Header And Logo

PostgreSQL
| The world's most advanced open source database.

Site Navigation

Search for
  Advanced Search

Re: Cascade constraint renames?


  • From: Richard Huxton <dev(at)archonet(dot)com>
  • To: Hannes Dorbath <light(at)theendofthetunnel(dot)de>
  • Cc: pgsql-general(at)postgresql(dot)org
  • Subject: Re: Cascade constraint renames?
  • Date: Wed, 26 Apr 2006 09:58:14 +0100
  • Message-id: <444F3626(dot)9080407(at)archonet(dot)com>

Hannes Dorbath wrote:
How to rename PK constraints that are referenced in various tables, without dropping down the entire dependency tree and recreate everything (at least all FKs) afterwards?

Dump-edit-reload is not an option, as the database size is way to huge.. :/

Not sure you can. There's no ALTER TABLE ... RENAME CONSTRAINT command. You might be able to do something by updating the system catalogues directly but I'd not feel comfortable doing so without a lot of testing.

Can I ask *why* you are renaming constraints? What difference does it make what they are called?

--
  Richard Huxton
  Archonet Ltd



Home | Main Index | Thread Index

Privacy Policy | PostgreSQL Archives hosted by Command Prompt, Inc. | Designed by tinysofa
Copyright © 1996 – 2008 PostgreSQL Global Development Group