Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
REPLACE Statement Efficiency
Message
From
23/06/2000 18:27:35
 
 
General information
Forum:
Visual FoxPro
Category:
Other
Miscellaneous
Thread ID:
00384060
Message ID:
00384120
Views:
38
>The first one is better time-wise because it does it once. It's especially noticable with REPLACE ALL.
>

Hey Michelle,

I know that if I used the second syntax with a REPLACE ALL VFP would take three trips through the database, but I'm curious as to whether internally VFP effectively converts the first form to three separate REPLACEs. The record is afterall in memory. The REPLACE statement should not actually generate any I/O until you move off the record right?

...kt
>
>
>>Generally speaking, is it more efficient to do something like
>>
>>REPLACE X WITH 1, Y WITH 2, Z WITH 3
>>
>>than
>>
>>REPLACE X WITH 1
>>REPLACE Y WITH 2
>>REPLACE Z WITH 3
>>
>>My suspicion is that the two are equivalent, but if anyone has different information, please share.
>>
>>Thanks,
>>
>> ...kt
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform