Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Anyone know how abort an executing SELECT - SQL...
Message
 
 
À
30/07/2001 16:17:06
Mike Sue-Ping
Cambridge, Ontario, Canada
Information générale
Forum:
Visual FoxPro
Catégorie:
Base de données, Tables, Vues, Index et syntaxe SQL
Divers
Thread ID:
00537446
Message ID:
00537477
Vues:
16
>I'm would like to know if it is possible to cancel/interrupt an executing SELECT - SQL command. My query could take a long time to finish and I would like to give the user the opportunity to abort the process. There is no WHILE clause to the VFP SELECT - SQL command. Does anyone know how I can do this? Please don't recommend that I try to optimize the query using RUSHMORE. The speed of the query is not my main concern here. The ability to abort the executing SELECT - SQL is.
>
>Thanks in advance for any suggestions.

From my colleague's code:
* support user Escapes for interrupting query processing
prevonesc = on('escape')			&& save previous Escape handler
prevescape = set('escape')			&& previous Escape enablement state
set escape on						&& enable escape handling
querhalt = .f.						&& allow loop to run until this flag is toggled
on escape querhalt = .t.			&& force immediate termination if user escapes
This would allow to terminate Query:
1) set talk is on (show progress bar)
2) after this progress bar actually appears on the screen.
If it's not broken, fix it until it is.


My Blog
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform