If you don't *need* this done with cfscript, try this.  This is a copy
and paste from something I'm putting together, with names changed to
protect the innocent...

<cfquery name="qLessons" datasource="coursesDB">                
        SELECT ID, Lesson, Required, Time FROM Lessons
</cfquery>

<cfprocessingdirective suppresswhitespace="Yes">
<cfcontent type="text/xml; charset=utf-16">
<cfxml variable="XMLDoc">
<?xml version='1.0' encoding='utf-8' ?>
<lData>
  <cfoutput query="qLessons">
    <Content>
        <cfloop FROM="1" TO="#ListLen(qLessons.ColumnList)#" index="i">
        
<#ListGetAt(qLessons.ColumnList,i)#>#qLessons[ListGetAt(qLessons.ColumnL
ist,i)][qLessons.currentrow]#</#ListGetAt(qLessons.ColumnList,i)#>
        </cfloop>
    </Content>
  </cfoutput>
</ldata>
</cfxml>
</cfprocessingdirective>
<cffile action="write" file="#wherever you want it saved#"
output="#XMLDoc#">

Matt Osbun
Web Developer
Health Systems, International

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Logware (www.logware.us): a new and convenient web-based time tracking 
application. Start tracking and documenting hours spent on a project or with a 
client with Logware today. Try it for free with a 15 day trial account.
http://www.houseoffusion.com/banners/view.cfm?bannerid=67

Message: http://www.houseoffusion.com/lists.cfm/link=i:4:211753
Archives: http://www.houseoffusion.com/cf_lists/threads.cfm/4
Subscription: http://www.houseoffusion.com/lists.cfm/link=s:4
Unsubscribe: 
http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4
Donations & Support: http://www.houseoffusion.com/tiny.cfm/54

Reply via email to