Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Replace All while not plStop
Message
De
26/06/2002 16:02:41
 
 
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Divers
Thread ID:
00672137
Message ID:
00672655
Vues:
7
This message has been marked as a message which has helped to the initial question of the thread.
Hi Nadya,

Well, like I was saying, I wouldn't bother with testing the speed between those 2 options...the one without the WHILE would not respond to the escape. It would stop making changes, but would continue to read every record in the file to test if it should do the replace.

IOW, my idea was a bad one, but I hit send before I noticed :)

>>Nadya,
>>
>>Well, I was going to suggest adding "and !plStop" to the FOR clause, but I think REPLACE would still continue reading records to determine if changes should be made...
>>
>
>Steve,
>
>I think your idea would work as well, but there are reasons, why I choose WHILE approach.
>
>We construct REPLACE command and then execute macro.
>
>If ForCondition is empty, we put ALL. I also think, that if we have FOR condition, we probably should put it in (), etc.
>
>So I choose the easier route. I didn't make any measurements, what is faster
REPLACE FOR (ForCond) and not plStop
>
>or
REPLACE FOR ForCond WHILE not plStop
>
>The table is table buffered. In addition validations should fire in batch mode (though I believe, I disabled them - but it's not my application, so they probably have to be re-activated).
>
>
< snip >
Steve Gibson
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform