Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
How to know if a table is locked?
Message
From
24/01/2000 17:44:30
Fausto Garcia
Independent Developer
Lima, Peru
 
General information
Forum:
Visual FoxPro
Category:
Databases,Tables, Views, Indexing and SQL syntax
Miscellaneous
Thread ID:
00321849
Message ID:
00321897
Views:
21
>>Hi to all,
>>
>>Is there a way to know if a table is locked in the middle of a transaction before opening it?
>>I tried using flock() but this works only if the table is open. What about checking a table lock status if it is closed? Isn't there a function as "locked()"?
>>
>>Thanks for your help,
>>
>>Fausto
>
>Fausto, cuando intentas bloquear una tabla que ya esta bloqueada se genera un mensaje de error, este mensaje puede ser manejado con la instruccion "ON ERROR". Para cualquier ayuda adicional puede referirte a la instruccion "TABLEUPDATE" o a la instruccion "ON ERROR" en la ayuda de VFP.
>
>Cualquier duda o comentario adicional puede contactarme por este mismo metodo.

Hola amigo,

Ciertamente, es lo que pense inicialmente, pero sucede que si yo deseo intentar el bloqueo de una tabla, debo tenerla abierta. Pero si esta tabla no la tengo abierta, está en medio de una transacción por otro usuario e intento abrirla con "use tabla", en im entorno de comandos de Visual FoxPro obtengo el mensaje "Registro en uso, por favor espere ... ", tampoco se activa la rutina "on error" y me imposibilita ejecutar cualquier otra acción hasta que la dichosa tabla quede libre de la transacción.
No sé si me hice entender. Espero tus comentarios.

Gracias,

Fausto
Solo se que nada se

Fausto J. Garcia Pino - MCSD.NET
.NET, Oracle, Tronador & Fondismo!
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform