User Guide

Chapter 18: Building Custom CFAPI Tags 323
query.setData( iRow, iFirstName, "John" ) ;
query.setData( iRow, iLastName, "Smith" ) ;
iRow = query.addRow() ;
query.setData( iRow, iFirstName, "Jane" ) ;
query.setData( iRow, iLastName, "Doe" ) ;
Parameters:
name — The name of the query to add to the template
columns — The column names to be used in the query
Returns:
The Query that was added to the template.
Throws:
IllegalArgumentException - if the name parameter is not a valid CFML variable
name
See Also:
Query.addRow, Query.setData
writeDebug
public void writeDebug(String output)
Writes text output into the debug stream. This text is only displayed to the end-
user if the tag contains the DEBUG attribute (you can check for this attribute using
the Request.debug member function).
The following example checks to see whether the DEBUG attribute is present, and
if it is then it writes a brief debug message:
if ( request.debug() )
{
response.writeDebug( "debug info" ) ;
}
Parameters:
output — The text to output
See Also:
Request.debug