Okay I fell stupid asking this because I have accomplished this many
times I just cant rememeber tonight.
<cfquery name="qry_STATES" datasource="CaptekLab">
SELECT PK_tblSTATEID, State
FROM dbo.tblSTATE
</cfquery>
<table>
<cfloop query="qry_states">
<cfquery name="qry_labs" datasource="CaptekLab">
SELECT FK_tblSTATEID, Lab_Name, Lab_City, Lap_Phone
FROM tblLABS
where fk_tblSTATEID = '#qry_states.pk_tblSTATEID#'
</cfquery>
<cfoutput query="qry_labs">
<tr>
<td>#qry_states.state#</td>
<td>#Lab_name#</td>
</tr>
</cfoutput>
</cfloop>
</table>
I want the state name output once and then a list of all the labs for
that state
IE
Alaska Lab1
Lab2
Lab3
Alabama Lab1
Lab2
Lab3
______________________________________________________________________
Your ad could be here. Monies from ads go to support these lists and provide more
resources for the community. http://www.fusionauthority.com/ads.cfm
FAQ: http://www.thenetprofits.co.uk/coldfusion/faq
Archives: http://www.mail-archive.com/[email protected]/
Unsubscribe: http://www.houseoffusion.com/index.cfm?sidebar=lists