Re: renaming+recreating table w/default sequence causes dependency seq issue - Mailing list pgsql-bugs

From Todd Kover
Subject Re: renaming+recreating table w/default sequence causes dependency seq issue
Date
Msg-id 201208082342.q78NgpB2019292@guinness.omniscient.com
Whole thread Raw
In response to Re: renaming+recreating table w/default sequence causes dependency seq issue  (Tom Lane <tgl@sss.pgh.pa.us>)
List pgsql-bugs
> I don't see any bug there.  The ALTER DROP DEFAULT command does not
 > remove the sequence's dependence on foo.id; nor for that matter
 > does ALTER SET DEFAULT create an auto-drop dependency on the new
 > table.  See ALTER SEQUENCE OWNED BY if you want to dissociate a
 > serial column's sequence from the column, or reattach it to another
 > column.
 >
 > Formally speaking, a "serial column" is shorthand for creating an
 > integer (or bigint) column, creating a sequence, associating them as
 > though by ALTER SEQUENCE OWNED BY, and setting the column's default
 > to nextval('sequence-name').

I stand corrected.  It would be nice if \ds or \ds+ or something showed
this relationship so it was evident.  That's more of a feature request
than a bug fix tho.

apologies for the misdirection.

-Todd

pgsql-bugs by date:

Previous
From: kargor
Date:
Subject: Re: BUG #6722: Debugger broken?
Next
From: Heikki Linnakangas
Date:
Subject: Re: BUG #6722: Debugger broken?