Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Problem Implementing RI in a Transaction
Message
 
 
À
Tous
Information générale
Forum:
Visual FoxPro
Catégorie:
Base de données, Tables, Vues, Index et syntaxe SQL
Titre:
Problem Implementing RI in a Transaction
Divers
Thread ID:
00570363
Message ID:
00570363
Vues:
51
Hi, all!

I implemented RI in my database and I am using the VMP4 default stored procedures.

In my application I have some forms where I have to update several table files in one transaction. I am using an updateable view for one of my tables and only one form control is bound to it. Inside beforedefaultupdates() method I included a logic that writes information to the rest of this updateable view and also to several related tables. Some of the 'other' tables are related to each other: one is the child of another. My problem is a 'Restrict' insert does not allow me to add records to the children tables although the foreign key was inserted into the parent table in the previous lines of code. This is because the new record in the parent table has not been committed. Please remember that these are all happening in a single transaction.

For now, I implemented an 'Ignore' insert but I should really enforce a 'Restrict' insert instead. Has anyone come across a situation like this? I appreciate any help.

Evelyn
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform