ColdFusion, AJAX and web...
<cfsavecontent variable="local.sData">
<cfoutput query="local.qData">#chr(34)##local.qData.col1##chr(34)#,
#chr(34)##local.qData.col2##chr(34)##chr(13)##chr(10)#
</cfoutput>
</cfsavecontent>
is a LOT quicker than:
<cfset local.sOutput = "">
<cfoutput query="local.qData">
<cfset local.sOutput = local.sOutput & chr(34) & local.qData.col1 & chr(34)>
<cfset local.sOutput = local.sOutput & chr(34) & local.qData.col2 & chr(34)>
<cfset local.sOutput = local.sOutput & chr(34) & local.qData.col3 & chr(34)>
<cfset local.sOutput = local.sOutput & chr(13) & chr(10)>
</cfoutput>
In this example, concatenating the string together can take up to 1 second. Using CFSAVECONTENT, the same string can take only 90 milliseconds to create (even with heaps more data).