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

Re: adding defaults

From: Peter Eisentraut <peter_e(at)gmx(dot)net>
To: Jodi Kanter <jkanter(at)virginia(dot)edu>,Postgres Admin List <pgsql-admin(at)postgresql(dot)org>
Subject: Re: adding defaults
Date: 2004-07-14 17:09:24
Message-ID: 200407141909.24359.peter_e@gmx.net (view raw or flat)
Thread:
Lists: pgsql-admin
Jodi Kanter wrote:
> Can field specific defaults easily be added to a table that is
> already in existence and has data in it?  I cannot seem to locate the
> correct ALTER command in any of my books.

ALTER TABLE a ALTER COLUMN b SET DEFAULT c;

-- 
Peter Eisentraut
http://developer.postgresql.org/~petere/


In response to

pgsql-admin by date

Next:From: Rosser SchwarzDate: 2004-07-14 17:11:51
Subject: Re: adding defaults
Previous:From: Oliver ElphickDate: 2004-07-14 16:52:21
Subject: Re: adding defaults

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group