Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Referential Integrity & Insert
Message
De
23/01/1999 12:49:42
 
 
À
23/01/1999 12:16:11
Information générale
Forum:
Visual FoxPro
Catégorie:
Autre
Divers
Thread ID:
00179374
Message ID:
00179407
Vues:
20
Hi Erik

Thank you for your reply to my post concerning restrict/ignore selections in the referential integrity builder. I believe the root of my problem is my lack of understanding to be quite honest! I may have things set up properly and FoxPro is just doing its job.

I was told that I always want to restrict on the insert column of the referential integrity builder. So, I didn't give it a second thought until I went to append a record to one of my tables and it gave me an error.

An example of one of my joins would be the following two tables. This is one of the tables that caused a problem when I went to append a record, to the child.

OFFICE TITLES table: This table holds names and descriptions of office titles (Ex. would be Mayor, Governor, County Commissioner, etc.) The primary key for this table is ntitle_id

OFFICES table: this table holds all the information you could ever want to know about an office (Ex. when the office will have its next election, description of office, precincts of that office, region of that office, etc.)

OFFICE TITLES is the parent and OFFICES is the child table.

The join is one to many. The logic behind the join is that one office title can have many offices (Ex. there can be a mayor (office title) of miami (office), Ft. Lauderdale (office), etc.

By the way, the primary key for Office titles is joined to a regular index key in my office table called ntitle_id

There is the design for those two tables in particular. Currently all my tables contain no information. The data entry has not been done.

My understanding of the "restrict" option for the insert is that it prohibits any additions to the child table if there isn't a related record in the parent.

> What should I be doing? Restricting of Ignoring. If it is restricting, how can I data entry into the child table if it will not let me, due to the error message? Do I have to data entry all my information first before I run the referential integrity?

I hope this helps you answer my question a litle better. I am confused just writing it!

Thanks again

Jason
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform