Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Buffering and locking questions
Message
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Divers
Thread ID:
00357538
Message ID:
00357771
Vues:
15
Steve,
Is there a reason for the pessimistic buffering? That locks the active record until you move to another. You might consider optimistic record buffering, and then do a quick check with OldVal() and CurVal() to see if a record has been changed. This way if a user goes to lunch (or to Europe for 3 months) leaving your program on you won't have records permanently locked. There are reasons for using pessimistic locking, but they are few and far between (IMHO).

HTH
Barbara

>I am using pessimistic buffering mode 2 (for record level) for my forms.
>
>1. When I have record buffering mode 2 turned on, do I ever need to do an UNLOCK command or is locking and unlocking done automatically for me when I move to another record using SKIP, SKIP - 1, GO TOP, GO BOTTOM, or whenever I open a new window (load/run DO FORM)?
>
>2. When I open my beginning form I am sitting at the bottom (last) record in the file. I go into Edit mode to update that record. But the record update spans several forms. When I load/run the second and third and forth forms I don't THISFORM.Release the opening form. Does that mean that the record will be locked or unlocked when I show the second, third or forth form? I read in the Programmer's Guide that the "record lock is released when you" move to another record or "activate another window".
>
>The reason I am asking these questions is that my record lock seems to be locking more than just the current record. I have done FLOCK() and been showing table locks in some code in the forms. Once I solve the locking/unlocking problems, my multi-user networking will be working.
>
>I know that the APPEND BLANK and REPLACE commands in my Edit burron are locking the record. But I don't know why pressing Top, Prev, Next, Bottom are also locking other records since I have not pressed the Edit button to lock the next or previous record. Thanks for the help.
Barbara Paltiel, Paltiel Inc.
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform