Re: Modifying check constraints

From: Stephan Szabo <sszabo(at)megazone23(dot)bigpanda(dot)com>
To: Paulo Jan <admin(at)mail(dot)ddnet(dot)es>
Cc: <pgsql-general(at)postgresql(dot)org>
Subject: Re: Modifying check constraints
Date: 2001-11-14 19:28:00
Message-ID: 20011114112731.P97884-100000@megazone23.bigpanda.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

On Wed, 14 Nov 2001, Paulo Jan wrote:

> Hi all:
>
> Let's suppose I create a table with a CHECK constraint, like:
>
> CREATE TABLE blabla (id int, tipo varchar(8),
> CHECK tipo IN ('tipo1', 'tipo2', 'tipo3'))
>
> Can I change the CHECK constraint afterwards? For example, can I
> add another value that "tipo" can have, or I'd have to recreate the
> table?

Right now, I think you'd need to recreate, but 7.2 should let you drop
and re-add the check constraint.

In response to

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Brent Verner 2001-11-14 20:00:32 where can I get mailing list archives in mbox format?
Previous Message Jason Earl 2001-11-14 19:07:05 Re: Modifying check constraints