Alexander,
Does your class allow to have two or more fields in the original result to be rows? VFPXTAB works fast enough on the simple test case, I tried, but I can not make it to create City and Frequency fields to be rows. I also want Count field to be followed by City Frequency and named Recorded and I want my columns (week data) to be named Wk_200202.., instead of C_200202, though it's not a big deal...
>Mr. President!
>Now file #
9944 available for downloading and I’m ready to continue discussion.
>
>>A particular case?? The cross-tabulation of data is a fairly generic process. I can't imagine a factor that would make a particular case unique. Perhaps the size of data. Then again, this would go back to the core design of the base program that would be useful in all situations.
>>
>>Sorry Alexander, I can't agree with your conclusion especially since you have offered no benchmarks to support your conclusion. To say that the program that ships with VFP cannot be slower is a conclusion that simply has no basis. I have used VFPXTAB on many occasions. I have also used Excel via automation for these tasks. Of the two, I'll take the VFP solution.
>
>My words were based on 8-year experience in FoxPro development beginning from FP 1.0. And I know that cross-tabulate queries never were a strong side of FP, especially compared with other desktop database systems. Of course, it’s not an argument. My sample is done in one evening and, so, is not a masterpiece of software development. But it shows that VFPXTAB works in 300 (THREE HUNDRED) times slower than my code. I think, it’s enough reason to repeat: “VFPXTAB is as slow as possible”. Not sure about VFP7, but think nothing changed. Let me know if it's not true.
>
>With best regards,
>Alexander
>
>P.S. You still have a chance to write a program even slower than vfpxtab.
>P.P.S. I hope, my next contribution to UT will be: "How to convert ADO recordset into VFP cursor", and don't tell me that Rs2Dbf can't be faster.
If it's not broken, fix it until it is.
My Blog