Re: [SQL] deferred constraints failing on commit

2001-01-18 Thread Stephan Szabo
Can you send the full schema of the tables you are using for this? On Tue, 16 Jan 2001, Michael Richards wrote: > Hi. > > I'm having trouble with committing a transaction. Intuitively it > should work but does not. > > I've got a table with 2 foreign keys, minrev and maxrev. They refer >

Re: [SQL] deferred constraints failing on commit

2001-01-18 Thread Stephan Szabo
Okay, yep, seems like a garden variety bug to me... What's happening is that the update trigger is checking to make sure that there are no rows referencing the one that was changed, but that's not sufficient for the deferred no action case possibly. It's got to be that there are no rows that no

Re: [SQL] deferred constraints failing on commit

2001-01-16 Thread Michael Richards
Here is a test case that illustrates the problem. I figured I was doing it all wrong before and didn't bother to distill and include a test case. create table objects( revisionid int4, primary key (revisionid)); create table objcatalog( minrev int4, maxrev int4, foreign key (minrev) references

[SQL] deferred constraints failing on commit

2001-01-16 Thread Michael Richards
Hi. I'm having trouble with committing a transaction. Intuitively it should work but does not. I've got a table with 2 foreign keys, minrev and maxrev. They refer to a the revisionid value in another table. I need to update the second table to reduce the revisionid, then insert a new row. At