Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
How much is VFP consultant worth?
Message
From
26/08/2022 05:03:54
Dragan Nedeljkovich (Online)
Now officially retired
Zrenjanin, Serbia
 
 
To
25/08/2022 23:23:45
General information
Forum:
Visual FoxPro
Category:
Contracts, agreements and general business
Miscellaneous
Thread ID:
01684849
Message ID:
01684900
Views:
50
>>Looking back on it now, those 5 minutes paid my salary for the entire year.
>>
>
>It's great to be able to recall those insights, isn't it? For me, they make this profession sizzle.

One of such moments was on my first US job. They had a flat, text table that resided in another app, written IIRC in Delphi, with the whole hospital departments hierarchy, down to the laundry. It would then get imported into a dbf, which was then recursively selected from to build the tree. Which took quite long, that's a hundred selects (including those that returned nothing because you're on a leaf node), and happened each time you opened a form which may need it.

I jumped in after „imported into a dbf“, which I made into a local cursor, and added a hierarchical key in it, then went through recursive scans to build that key for each record, and then indexed by it. The speed gain was twenty times.

The last one, on the same job, was an import from a text file. The initial version was reading it byte by byte, like an elementary parser, sometimes even doing a fseek() backwards (!). Obviously whoever wrote it knew nothing of aLines(), let alone its parameters. The last version had to be special, because the assortment of columns in the incoming csv varied, so to avoid checking for each column for each row, I had a type object which would handle each column, and included objects for each present column - so checking for them only once, at the header row. By my calculation, it saved me about 40000 IFs per run, on the average.

back to same old

the first online autobiography, unfinished by design
What, me reckless? I'm full of recks!
Balkans, eh? Count them.
Previous
Reply
Map
View

Click here to load this message in the networking platform