Walter,
I had already taken care of some of it + put some to match C# output but simply missed there was .T. in textmerge :)
StartTime = SECONDS()
SELECT * FROM testcursor INTO CURSOR TEST
=AFIELDS(laFields, "Testcursor")
cString = Chr(13) + Chr(9) + "<CLIENT>" + Chr(13)
FOR nT = 1 TO ALEN(laFields,1)
cString = m.cString + Chr(9) + Chr(9) + ;
"<"+laFields(nT,1)+">%%"+laFields(nT,1)+"%%</"+;
laFields(nT,1)+">" + Chr(13)
ENDFOR
cString = cString + Chr(9) + "</CLIENT>"
SET TEXTMERGE DELIMITERS TO "%%","%%"
SET TEXTMERGE TO "cxml.txt" noshow
SET TEXTMERGE ON
\\<TEST>
SCAN
TEXTMERGE(m.cString)
ENDSCAN
\</TEST>
SET TEXTMERGE OFF
SET TEXTMERGE TO
cXml = FILETOSTR("cxml.txt")
?SECONDS() - StartTime
This version (removing .T. from textmerge only) has a timing of 9-10 secs.
Cetin
>>Hi Walter,
>>I tried your version and with repeated calls it has timing around 17-26 secs.
>
>Hmmm, I think there are some other circumstances which make up the difference. Are you referring to
Re: Side by side comparison (strings & local data) Thread #
861648 Message #
861698>
>My example seems to be about twice as fast as this when testing it with various cursor with different length and width.
>
>Can you put a SET CONSOLE OFF at the beginning (so it does not output the result to the display) and remove the .T. parameter from the TEXTMERGE(cString,.T.) and check the results again ?
>