Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
VFP6 How to detect a table in use by views
Message
 
À
05/10/2004 06:12:13
Cetin Basoz
Engineerica Inc.
Izmir, Turquie
Information générale
Forum:
Visual FoxPro
Catégorie:
Base de données, Tables, Vues, Index et syntaxe SQL
Divers
Thread ID:
00948339
Message ID:
00948746
Vues:
15
Hi Cetin

>-Get a list of tables that need to be used exclusively in a chain operation (ie: delete and pack records from a table. This should in turn affect a series of child tables either by removing -deleting- or orphaning them. What RI does in its simple form but my own RI implementation.)

Okay, done

>-Should the operation fail or continue if anyone of them cannot be used exclusively

In this situation dele pack as and when available, but yes in serious apps there could be a situation where all the required tables are to be exclusive before proceeding.

>-To try to take them into exclusive mode check sessions they're used and take action as appropriate

You mean all together at the very begining, no matter how long the actual process takes, then here it is okay but serious apps yes.

>-Backup

What? <g> With my experience of providing backup routines in the app, the users end up troubling us more for third party utilities then for the app itself <g>. But yes I have warned the user on the form in red.

>-Loop the tables to operate on and do whatever

Okay

>-Inform the user of the steps you're performing

Anything simple, I generally use WAIT WINDOWS NOWAITs

>Well even outlining was not easy at the moment:)

Looks complete to me nevertheless. Thanks.

>I'd instead make it simple:
>
>
on error llHadError = .t.
>use myTable exclusive in 0
>on error
>if m.llHadError
> aerror(arrErr)
> ? 'Error',arrErr,message(),message(1)
>else
> * do whatever
>endif
We can maybe have a ExclOpenTble() function borrowing and expanding the name from Nadya's function. Or maybe put in a shortcircuit logic in Nadya's function when EXCLUSIVE is specified.
Regards
Bhavbhuti
___________________________________________
Softwares for Indian Businesses at:
http://venussoftop.tripod.com
___________________________________________
venussoftop@gmail.com
___________________________________________
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform