Talk About Network

Google


Register and Login
Nick
Password
Register create new account Sign up is FREE and you can post replies, new topics, bookmark posts and more!
Recover lost password


Data Bases > Pgsql Sql > apparent RI bug
Latest [ Topics | Posts ] Archive Post A New Topic Post a Reply
<< Topic < Post Post 1 of 7 Topic 3383 of 3596
Post > Topic >>

apparent RI bug

by chestercyoung@[EMAIL PROTECTED] (chester c young) Apr 2, 2008 at 10:42 AM

it appears I have a broken RI in my db.

call_individual.clh_id references call_household.clh_id

\d call_individual
....
Foreign-key constraints:
    "call_individual_clh_id_fkey" FOREIGN KEY (clh_id) REFERENCES
call_household(clh_id) ON DELETE CASCADE

however:
development=# select clh_id from call_individual cli where not exists(
select 1 from call_household clh where clh.clh_id=cli.clh_id );
 clh_id 
--------
  14691

should not matter, but call_individual has a pre-delete trigger that
simply raises an exception to prevent deletions:
        raise exception 'calls may not be deleted';



     
____________________________________________________________________________________
You rock. That's why Blockbuster's offering you one month of Blockbuster
Total Access, No Cost.  
http://tc.deals.yahoo.com/tc/blockbuster/text5.com

-- 
Sent via pgsql-sql mailing list (pgsql-sql@[EMAIL PROTECTED]
)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-sql
 




 7 Posts in Topic:
apparent RI bug
chestercyoung@[EMAIL PROT  2008-04-02 10:42:36 
Re: apparent RI bug
sszabo@[EMAIL PROTECTED]   2008-04-03 10:31:19 
Re: apparent RI bug
chestercyoung@[EMAIL PROT  2008-04-03 11:13:13 
Re: apparent RI bug
sszabo@[EMAIL PROTECTED]   2008-04-03 11:33:05 
Re: apparent RI bug
chestercyoung@[EMAIL PROT  2008-04-03 13:16:42 
Re: apparent RI bug
sszabo@[EMAIL PROTECTED]   2008-04-03 13:35:15 
Re: apparent RI bug
chestercyoung@[EMAIL PROT  2008-04-03 18:53:03 

Post A Reply:
  Go here to Signup

AddThis Feed Button


About - Advertising - Contact - Frequently Asked Questions - Privacy Policy - Terms of Use - Signup

Contact
tan13V112 Thu Jul 24 6:55:36 CDT 2008.