Re: multiple default values specified for column? - Mailing list pgsql-general

From Tom Lane
Subject Re: multiple default values specified for column?
Date
Msg-id 3811.1128695657@sss.pgh.pa.us
Whole thread Raw
In response to multiple default values specified for column?  (smorrey@gmail.com)
List pgsql-general
smorrey@gmail.com writes:
> ERROR:  multiple default values specified for column "txnid" of table
> "ec_transaction"

> CREATE TABLE ec_transaction (
>     txnid BIGSERIAL NOT NULL DEFAULT
> nextval('public.ec_transaction_txnid_seq') ,

SERIAL/BIGSERIAL implies a default clause.  If you want to attach the
column to a pre-existing sequence, just declare it int or bigint.

            regards, tom lane

pgsql-general by date:

Previous
From: Alvaro Herrera
Date:
Subject: Re: [HACKERS] Shell script to extract a table from a plain text dump
Next
From: Stephan Szabo
Date:
Subject: Re: multiple default values specified for column?