Disable Constraints in Postgresql 8.4

From: Jyoti Seth <jyotiseth2001(at)gmail(dot)com>
To: pgsql-sql(at)postgresql(dot)org
Subject: Disable Constraints in Postgresql 8.4
Date: 2009-09-29 08:52:14
Message-ID: 25659252.post@talk.nabble.com
Views: Whole Thread | Raw Message | Download mbox | Resend email
Thread:
Lists: pgsql-sql


I want to execute a sql file for that I need to disable constraints.

In postgres version 8.3, I was executing the script by doing the
following:
1. Disabling triggers by updating “reltriggers” field of pg_class to 0 .
2. Executing sql file
3. Then updating “reltriggers” field of pg_class by “select count(*) from
pg_trigger where pg_trigger.tgrelid=pg_class.oid”

In postgres version 8.4, “pg_class” table does not have “reltriggers” field.

How can I disable and enable constraints in Postgres Version 8.4?

--
View this message in context: http://www.nabble.com/Disable-Constraints-in-Postgresql-8.4-tp25659252p25659252.html
Sent from the PostgreSQL - sql mailing list archive at Nabble.com.

Responses

Browse pgsql-sql by date

  From Date Subject
Next Message Tom Lane 2009-09-29 14:13:05 Re: Disable Constraints in Postgresql 8.4
Previous Message the6campbells 2009-09-29 02:54:35 Common table expression - parsing questions