Do a GROUP BY in your query... then start a table, and a table row... then

<CFOUTPUT QUERY="queryname" GROUP="categoryfieldname">
<td>#categoryname#<BR>---------<BR>
<CFOUTPUT GROUP="itemfieldname">
#itemname#<BR>
</CFOUTPUT>
</td>
</CFOUTPUT>

and close the row/table. That way, each category has its own column.

--Scott

----- Original Message -----
From: "Richard Colman" <[EMAIL PROTECTED]>
To: "CF-Talk" <[EMAIL PROTECTED]>
Sent: Monday, October 16, 2000 3:28 PM
Subject: outputting data in a matrix


> Can someone suggest how to do this:
>
> category1  category2    category3
> --------   ----------   -------
> item 1      item 1       item 1
> item 2      item 2       item 2
> item 3      item 3
>             item 4
>
>
> where the data table looks like:
>
> category, item, etc.
>
> there will be an unequal number of items per category.
>
> ideas for an approach appreciated. Thank you.
>
> Richard Colman
>
> --------------------------------------------------------------------------
----
> Archives: http://www.mail-archive.com/[email protected]/
> To Unsubscribe visit
http://www.houseoffusion.com/index.cfm?sidebar=lists&body=lists/cf_talk or
send a message to [EMAIL PROTECTED] with 'unsubscribe' in
the body.
>

------------------------------------------------------------------------------
Archives: http://www.mail-archive.com/[email protected]/
To Unsubscribe visit 
http://www.houseoffusion.com/index.cfm?sidebar=lists&body=lists/cf_talk or send a 
message to [EMAIL PROTECTED] with 'unsubscribe' in the body.

Reply via email to