From: | Josep Sànchez i Mesegué <jsmesegue(at)transpujol(dot)com> |
---|---|
To: | pgsql-novice(at)postgresql(dot)org |
Subject: | Altering table error |
Date: | 2003-05-19 09:43:44 |
Message-ID: | 3EC8A750.10604@transpujol.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-novice |
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
I'm trying to alter an existing table, whith data in it, adding a column
called "cap_id" that should be a "serial" or "serial8" type, but when I
try to do it I receive the next message:
| provesmasis-# provesmasis=# alter table captrajectes add column cap_id
serial;
| NOTICE: ALTER TABLE will create implicit sequence
'captrajectes_cap_id_seq' for SERIAL column 'captrajectes.cap_id'
| NOTICE: ALTER TABLE / ADD UNIQUE will create implicit index
'captrajectes_cap_id_key' for table 'captrajectes'
| ERROR: parser: parse error at or near "notice"
| provesmasis=# NOTICE: ALTER TABLE will create implicit sequence
'captrajectes_cap_id_seq' for SERIAL column 'captrajectes.cap_id'
| provesmasis-# NOTICE: ALTER TABLE / ADD UNIQUE will create implicit
index 'captrajectes_cap_id_key' for table 'captrajectes'
| provesmasis-# ERROR: Adding columns with defaults is not implemented.
| provesmasis-# Add the column, then use ALTER TABLE SET DEFAULT.
What am I doing wrong?
Thanks in advance for your answer.
Josep Sànchez
~ [papapep]
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.1 (MingW32)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org
iD8DBQE+yKdP2vx52x0kyz4RAur2AJ9eIeWADsUJcB2E7jTgNA0fr/qQBACfevpE
zdKjuFf2YB4K+x1S7LdYC2c=
=HAAd
-----END PGP SIGNATURE-----
From | Date | Subject | |
---|---|---|---|
Next Message | Nabil Sayegh | 2003-05-19 10:35:19 | 7.2.1 => 7.3.2 |
Previous Message | Dani Oderbolz | 2003-05-18 12:04:43 | Re: Problems with join (no such attribute, but it exists) |