![]() | |
![]() |
| | Thread Tools | Display Modes |
#1
| |||
| |||
|
|
Hi all, trying to create a table with a column xmin I get the following error message: test=> create table lx (xmin int); ERROR: column name "xmin" conflicts with a system column name Instead I get a different (and less understandable) error message if I try to add a column named xmin to an existent table: test=> create table lx (i int); CREATE TABLE test=> alter table lx add xmin int; ERROR: column "xmin" of relation "lx" already exists. The same problem occurs using "xmax" as column name. I'm on Ubuntu 11.04. Tried on both PostgreSQL 8.4.10 and 9.1.2 |
#2
| |||
| |||
|
|
Am 22.01.12 14:22, schrieb Giuseppe Sucameli: test=> create table lx (xmin int); ERROR: column name "xmin" conflicts with a system column name test=> create table lx (i int); CREATE TABLE test=> alter table lx add xmin int; ERROR: column "xmin" of relation "lx" already exists. That is not a bug, but a feature. |
#3
| |||
| |||
|
|
On Mon, Jan 23, 2012 at 11:25, Marc Balmer <marc (AT) msys (DOT) ch> wrote: Am 22.01.12 14:22, schrieb Giuseppe Sucameli: test=> create table lx (i int); CREATE TABLE test=> alter table lx add xmin int; ERROR: *column "xmin" of relation "lx" already exists. That is not a bug, but a feature. I see it as a message bug.* Why wouldn't ALTER TABLE also tell us that xmin is a system column?* It makes things much more clear for newbies who don't see the column yet are told it exists if they're also told it's a system column. |
|
I would try to cook up a patch but I have no skills :-( |
#4
| |||
| |||
|
|
I would try to cook up a patch but I have no skills :-( I'm going to write a patch to fix this problem. |
#5
| |||
| |||
|
|
On Tue, Jan 24, 2012 at 14:41, Giuseppe Sucameli <brush.tyler (AT) gmail (DOT) com wrote: I would try to cook up a patch but I have no skills :-( I'm going to write a patch to fix this problem. I managed to put something together and have posted it on hackers. |
#6
| |||
| |||
|
|
thinking you have no skills, I wrote a patch too and posted it to hackers ML about 2 days ago, but I didn't subscribe that list so it is stalled, waiting for someone's approval. For this reason my email is not displayed in the archives. I'm so sorry both have wasted our time in writing 2 patches for the same bug. |
#7
| |||
| |||
|
|
On Wed, Jan 25, 2012 at 22:19, Giuseppe Sucameli <brush.tyler (AT) gmail (DOT) com wrote: thinking you have no skills, I wrote a patch too and posted it to hackers ML about 2 days ago, but I didn't subscribe that list so it is stalled, waiting for someone's approval. For this reason my email is not displayed in the archives. I'm so sorry both have wasted our time in writing 2 patches for the same bug. I think your patch is more complete than mine so it's definitely not wasted.* I spent several hours on mine and now I have a little bit of skills :-) Thank you for your effort; I'm sorry if you feel you have wasted your time. |
![]() |
| Thread Tools | |
| Display Modes | |
| |