Search Postgresql Archives

Re: Foreign key behavior different in a function and outside

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 05/03/10 18:12, Mridula Mahadevan wrote:
Richard, To answer your questions, I have a live application that is
running on postgresql. We are seeing this issue on certain
installations and not on others. So the code is no different in each
set up. I also added the trigger to table B and then the foreign key
error is thrown in all set ups. But without the trigger a delete on
table B from within a function assumes cascade delete even when one
is not specified. Again only in some cases, I can send you the entire
procedure if it helps (the one I have below only has the relevant
parts).

But does the test code you sent show this problem on:
1. all installations
2. some installations
3. none of the installations
4. Don't know - haven't tried the test code

If the test code shows the problem then we know it's something basic in your PostgreSQL installations. If it doesn't then it's something in the setup of the databases.

I don't think the problem has anything to do with the code of the function. You have checked that the code in your functions makes sense and looked at it on servers where it works and it doesn't. If the problem was there I'm sure you'd have seen it.


--
  Richard Huxton
  Archonet Ltd

--
Sent via pgsql-general mailing list (pgsql-general@xxxxxxxxxxxxxx)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-general

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Postgresql Jobs]     [Postgresql Admin]     [Postgresql Performance]     [Linux Clusters]     [PHP Home]     [PHP on Windows]     [Kernel Newbies]     [PHP Classes]     [PHP Books]     [PHP Databases]     [Postgresql & PHP]     [Yosemite]
  Powered by Linux