Why is there no ADD CONSTRAINT IF NOT EXISTS ?

From: Stephen Carboni <stephen(dot)entropy(at)gmail(dot)com>
To: pgsql-novice(at)postgresql(dot)org
Subject: Why is there no ADD CONSTRAINT IF NOT EXISTS ?
Date: 2021-04-21 12:13:19
Message-ID: CAN-rLW_L0s-nt5AC5A=RLtCjeB-aaZRd-oRfkKf0OeYXCNzHng@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-novice

I can drop a constraint if it exists, but cannot simply add one if it does
not exist. Is there something especially difficult about supporting this?

Responses

Browse pgsql-novice by date

  From Date Subject
Next Message Tom Lane 2021-04-21 14:08:00 Re: Why is there no ADD CONSTRAINT IF NOT EXISTS ?
Previous Message Simon Connah 2021-04-18 19:07:46 Re: Dealing with multiple currencies with the money type?