1 2
3 4
5 6
OR
1 4
2 5
3 6
The former is pretty easy.
<cfoutput>
<table>
<cfloop from=1 to=#query.recordcount step=2 index=i>
<tr><td>#query.column[i]#</td><td>#query.column[i+1]#</td></tr>
</cfloop>
</table>
</cfoutput>
The latter takes a couple more lines.
<cfset secCol = false>
<cfoutput>
<table>
<tr><td>
<cfloop query=queryName>
#query.column#
<cfif query.currentRow GTE query.recordcount / 2 AND NOT secCol>
</td><td>
<cfset secCol = true>
</cfif>
</cfloop>
</td></tr>
</table>
<cfoutput>
That should give you the basics modify as you desire to use the formatting
method of your choice to create the columnated display.
--------------
Ian Skinner
Web Programmer
BloodSource
www.BloodSource.org
Sacramento, CA
-----Original Message-----
From: Tim Laureska [mailto:[EMAIL PROTECTED]
Sent: Monday, December 22, 2003 11:28 AM
To: CF-Talk
Subject: query output to columns
Can someone provide a tip on how to make a query result wrap to a second
column so that you have two columns side by side for output
TIA
Tim Laureska
_____
[Todays Threads] [This Message] [Subscription] [Fast Unsubscribe] [User Settings]

