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

Re: Bug #616: Alter table add foreign key

From: Stefano Reksten <sreksten(at)sdb(dot)it>
To: pgsql-bugs(at)postgresql(dot)org
Subject: Re: Bug #616: Alter table add foreign key
Date: 2002-03-15 12:39:29
Message-ID: (view raw, whole thread or download thread mbox)
Lists: pgsql-bugs
At 07.24 15/03/02 -0500, you wrote:
>I tried to execute following SQL alter table PRICEGROUP add FOREIGN 
>this gives an error ALTER TABLE: column "PARENT" referenced in foreign key 
>constraint does not exist (7) while I'm sure that the column exists and is 
>Non null. I'm using version 7.2 on linux redhat 7.2

Hello Dirk,
if you are using double quotes around the column name the name won't be 
translated in lowercase; maybe the column name wasn't created this way and 
that's why you caon't find it. Try to
alter table pricegroup add foreign key (parent) references pricegroup on 
delete cascade
without using double quotes.

Just my 0.02


In response to

pgsql-bugs by date

Next:From: 'Ben Grimm'Date: 2002-03-15 13:23:58
Subject: Re: Bug #613: Sequence values fall back to previously chec
Previous:From: pgsql-bugsDate: 2002-03-15 12:36:24
Subject: Bug #619: Not possible to specify foreign key name

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