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

Re: Bug in FOREIGN KEY

From: Bruce Momjian <pgman(at)candle(dot)pha(dot)pa(dot)us>
To: Jan Wieck <janwieck(at)yahoo(dot)com>
Cc: Peter Eisentraut <peter_e(at)gmx(dot)net>, PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: Bug in FOREIGN KEY
Date: 2001-01-26 22:03:22
Message-ID: 200101262203.RAA10859@candle.pha.pa.us (view raw or flat)
Thread:
Lists: pgsql-hackers
> Bruce Momjian wrote:
> > Here is another bug:
> >
> > test=> begin;
> > BEGIN
> > test=> INSERT INTO primarytest2 VALUES (5,5);
> > INSERT 18757 1
> > test=> UPDATE primarytest2 SET col2=1 WHERE col1 = 5 AND col2 = 5;
> > ERROR:  deferredTriggerGetPreviousEvent: event for tuple (0,10) not
> > found
> 
>     Schema?
> 

CREATE TABLE primarytest2 (
                           col1 INTEGER, 
                           col2 INTEGER, 
                           PRIMARY KEY(col1, col2)
                          );

CREATE TABLE foreigntest2 (col3 INTEGER, 
                           col4 INTEGER,
                           FOREIGN KEY (col3, col4) REFERENCES primarytest2
                         );

-- 
  Bruce Momjian                        |  http://candle.pha.pa.us
  pgman(at)candle(dot)pha(dot)pa(dot)us               |  (610) 853-3000
  +  If your life is a hard drive,     |  830 Blythe Avenue
  +  Christ can be your backup.        |  Drexel Hill, Pennsylvania 19026

In response to

Responses

pgsql-hackers by date

Next:From: Jan WieckDate: 2001-01-26 22:06:24
Subject: Re: Sure enough, the lock file is gone
Previous:From: Jan WieckDate: 2001-01-26 22:02:32
Subject: Re: Bug in FOREIGN KEY

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