David,
I didn't blame VFP for that. The point was that the file needed to be parsed to get it done. With regular expressions I just needed to look for a pattern (telephone number) and do the crunching from there. Even this solution was done from within VFP (!), we just took a little side-step to get faster results.
In the end everybody was happy because we reduced the process to seconds and not minutes.
I sometimes like to think outside of the (VFP)box to get results. Don't get me wrong, VFP is more than great for what I need to do.
Regards,
Ron
>Ranjan,
>
>If the VFP code took 20 minutes to process a 25mb file the code was not written in a very efficient manner. Don't blame VFP for that sort of fault. It probably could have been written in a manner that would execute within a few seconds. It still wouldn't be as fast as the underlying C/C++ code being executed inside the regexp utility.
>
>>Doing this with vbscript is a lot easier and faster. I once needed to convert a file with generated by a telephonecentral and needed to put a CR in between two telephone numbers. I used VFP and a 25 Mb file took over 20 minutes. Someone pointed me towards vbscript and regular expressions and that did the same trick (with a pattern) under 2 seconds. Why should this be done explicitly by VFP. Some tools sometimes perform faster.
Previous
Next
Reply
View the map of this thread
View the map of this thread starting from this message only
View all messages of this thread
View all messages of this thread starting from this message only