Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

RI Code Not Working Correctly 1

Status
Not open for further replies.

ToddWW

Programmer
Mar 25, 2001
1,073
US
I have been working with FoxPro since v3. Currently working with VFP 8. I have a database with one table that has a primary key and a second table with a regular key. I create the join and click the button to modify the referential integrity. All three (insert,delete,update) default to ignore. I change them all to restrict. The update works and the delete works, but the insert does not seem to be working. I can still insert a record into the 2nd table with a value that does not exist in the parent table. Is there some global setting I'm missing?
 
So you can insert a value into the field with regular index (foreign key), which does not exist as a primary key in the parent table?

Did you open the database exclusive? Did you not just set the referential integrity options for each relation, but also let the referential integrity builder build the stored procedure code to apply the referential integrity rules?

Bye, Olaf.
 
Thank You Olaf. It didn't solve my problem but it made me realize I was setting up my indexes incorrectly all these years!! Yikes!! So I guess, in the long run, it did solve my problem. Thanks again.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top