Re: PostgreSQL Constraints and Foreign Keys - Dropping Tables

From: "David G(dot) Johnston" <david(dot)g(dot)johnston(at)gmail(dot)com>
To: Sbob <sbob(at)quadratum-braccas(dot)com>
Cc: Pgsql-admin <pgsql-admin(at)lists(dot)postgresql(dot)org>
Subject: Re: PostgreSQL Constraints and Foreign Keys - Dropping Tables
Date: 2022-12-08 21:40:10
Message-ID: CAKFQuwb1NBGVMyNk-TZWv2CNZxMJFYQLws+rj-7F+742K==QaQ@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-admin

On Thu, Dec 8, 2022 at 2:36 PM Sbob <sbob(at)quadratum-braccas(dot)com> wrote:

> I just saw a post indicating that PostgreSQL Foreign Keys and
> Constraints are actually managed via triggers, therefore instead of
> doing a DROP TABLE CASCADE I could just disable triggers.
>

Those two things don't produce the same end result...

> If so it 'feels' like there may be dangerous side effects, any thoughts
> on any cautions and gotcha's to this approach?
>
>
Why did you add constraints/foreign keys in the first place?

David J.

In response to

Browse pgsql-admin by date

  From Date Subject
Next Message SASIKUMAR Devaraj 2022-12-09 05:02:59 How to speed WAL apply in destination
Previous Message Sbob 2022-12-08 21:36:27 PostgreSQL Constraints and Foreign Keys - Dropping Tables