Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
How get the Number of Lines from a text file
Message
 
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Miscellaneous
Thread ID:
00451983
Message ID:
00452083
Views:
56
Nadya,

The APPEND into a C(1) cursor is likely to be the absolute fastest. It will work on files even in the GB range as long as there are not more than one gig lines.

The APPEND will work faster because it's one command down to the native C++ code. The fgets() loop solution will keep making interpretive VFP code execution for each line.

>>>Yeah, right. Ok, give us few other ways, please... :)
>>
>>There are several in this thread.
>
>I mean, for the BIG BIG files... I bet low-level functions is the best choice. Copy to cursor and then memlines could probably work too, but I think, low-level would be much faster...
df (was a 10 time MVP)

df FoxPro website
FoxPro Wiki site online, editable knowledgebase
Previous
Reply
Map
View

Click here to load this message in the networking platform