Thanks To: Bud Schneehagen - Tropical Web Creations _/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/ ColdFusion Solutions / eCommerce Development [EMAIL PROTECTED] http://www.twcreations.com/ 954.721.3452
I really do appreciate the great help i have recieved here... The code that did it! -paul <cfquery name="rsEmployee" datasource="ISresource" dbtype="ODBC"> SELECT DISTINCT EmployeeID, LastName, FirstName FROM tblEmployee ORDER BY LastName; </cfquery> <cfquery name="myRelations" datasource="ISresource" dbtype="ODBC"> SELECT DISTINCT Relation_ID, tblRelations.Service_ID, tblRelations.EmployeeID, tblService.Service_ID, tblService.Service, tblEmployee.EmployeeID, LastName, FirstName FROM tblRelations, tblService, tblEmployee WHERE tblRelations.Service_ID = tblService.Service_ID AND tblRelations.EmployeeID IN (tblEmployee.EmployeeID) ORDER BY Service, LastName;</cfquery> <cfscript> rsEmployee_NumRows = 0; rsEmployee_Index = 1; HLooper1_NumRows = 20; rsEmployee_NumRows = rsEmployee_NumRows + HLooper1_NumRows; </cfscript> <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN"> <html> <head> <title>Untitled</title> </head> <body> <table border="1"> <tr> <td bgcolor="#C0C0C0">Resource</td> <cfoutput query="rsEmployee"> <td align="center"> #LEFT(rsEmployee.FirstName, 1)#.#LEFT(rsEmployee.LastName, 1)#. #rsEmployee.EmployeeID# </td> </cfoutput> </tr> <tr> <cfoutput query="myRelations" group="Service_ID"> <!--- Added next 2 lines to create a list of employees subscribed to the service ---> <cfset employees = ""> <CFOUTPUT group="Relation_ID"> <cfset employees = listappend(employees, EmployeeID)> </CFOUTPUT> <td>#Trim(myRelations.Service)#</td> <cfloop query="rsEmployee"> <td> <cfif listfind(employees, rsEmployee.EmployeeID)> <strong>#rsEmployee.EmployeeID#</strong> <CFELSE> <em>#rsEmployee.EmployeeID#</em> </CFIF> </td> </cfloop> </tr><tr> </CFOUTPUT> <td colspan="<cfoutput>#int(rsEmployee.recordcount + 1)#</cfoutput>"></td> </tr> </table> </body> </html> ______________________________________________________________________ Structure your ColdFusion code with Fusebox. Get the official book at http://www.fusionauthority.com/bkinfo.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

