Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Can this approach corrupt table?
Message
 
 
À
Tous
Information générale
Forum:
Visual FoxPro
Catégorie:
Autre
Titre:
Can this approach corrupt table?
Versions des environnements
Visual FoxPro:
VFP 9 SP1
Divers
Thread ID:
01553564
Message ID:
01553564
Vues:
135
Hi,

Lately a few customers reported to me table corruption with one specific table. Which made me think of possibly flawed design I implemented. Here is the description of the design - in general terms.

I have a BIZ base class that is used for pretty much all tables of the application. For example, a form can instantiate any number of the BIZ classes based on this class, depending on the tables used (e.g. Vendors, Staff, Parts, etc.). In the INIT method of the base BIZ class a BIZ class to an audit table is instantiated (using the same base class). Therefore, each BIZ class has a reference (class property) to a BIZ class of this audit table. All BIZ classes use CursorAdapter to connect to the base tables. And therefore at any given time there could be a number of BIZ classes "pointing" to the same physical table (audit table). This audit table is the one that gets corrupted. Could this approach cause the corruption? I am thinking of redesigning the base BIZ class and NOT to instantiate the Audit Table BIZ class but rather do just one BIZ class for the entire data session. But before I go through tons of work of rewriting this, I would like to hear your input.

TIA.
"The creative process is nothing but a series of crises." Isaac Bashevis Singer
"My experience is that as soon as people are old enough to know better, they don't know anything at all." Oscar Wilde
"If a nation values anything more than freedom, it will lose its freedom; and the irony of it is that if it is comfort or money that it values more, it will lose that too." W.Somerset Maugham
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform