queryColumnList

Returns the column names of a query as a list.

queryColumnList(query [, delimiter]) → returns string

Member Function Syntax

query.columnList([delimiter])

This function requires Lucee. Not supported on Adobe ColdFusion.

queryColumnList Argument Reference

query
Required

delimiter
Default: ,

Examples sample code invoking the queryColumnList function


Create a query and output the column list

myQuery = queryNew( 'ID,name,age' );
writeOutput( queryColumnList( myQuery ) );

Expected Result: ID,name,age


Using a member function

myQuery = queryNew( 'ID,name,age' );
writeOutput( myQuery.columnList() );

Expected Result: ID,name,age


Fork me on GitHub