In my query I need to loop through the courses and find out wheather or not 
perosn require to take courses. if the do not require to take any courses then 
mark the cell N/a. If they do require then check for completion. If they had 
already taking the course and completed then leave the cell blank. If they 
required but never completed then marked X. I did the cfloop over this issue 
but 
does not seems to be working . I do not know what to do next 

SO the way I loop is follow: 
<cfloop query="getReport">
    
                     
                        <cfif lastEmp neq EmployeeiD>
                                <cfif lastEmp neq "***">
                                        <tr>
                                                <td valign="top" 
>#arryEmployees[1]#</td>
                                                <td valign="top" 
class="tdctr">#arryEmployees[2]#</td>
                                                <td valign="top">#holdemp#</td>
                
                                                <cfloop from="1" 
to="#ArrayLen(arryCourses)#" index="i">
                   
                                
                      <td valign="top" class="tdctr">#IIF (comparray[i] gt 
"",DE(""),DE("X"))#</td>  
                     
             
                                                </cfloop>
                        <cfoutput>#count#</cfoutput>
                                        </tr>
                
                                </cfif>
                                <cfset holdemp = "#last_Name#, #First_Name#">
                                <cfloop from="1" to="#ArrayLen(arryCourses)#" 
index="i">
                                        <cfset comparray[i] = "">
                                </cfloop>
                        </cfif>
                        <cfif lastLocation neq LocationID>
                                <cfif lastLocation neq "***">
                                        <tr>
                                                <th valign="top" 
class="yellowBgCenter">#arryEmployees[1]#</th>
                                                <th valign="top" 
class="yellowBgCenter">#arryEmployees[2]#</th>
                                                <th valign="top" 
class="yellowBgCenter">Totals</th>
                                                <cfloop from="1" 
to="#ArrayLen(arryCourses)#" index="i">
                                                        <td valign="top" 
class="yellowBgCenter">#arryCntTotals[i][1]#</td>
                                                        <cfset 
arryCntTotals[i][1] = 0>
                                                </cfloop>
                                        </tr>
                                </cfif>
                        </cfif>
                        <!--- process this record --->
                        <cfset arryEmployees[1] = "#Name#">
                        <cfset arryEmployees[2] = "#locationID#">
   


       
                <cfloop from="1" to="#ArrayLen(arryCourses)#" index="i">
                
                                <cfif coursename eq "#arryCourses[i][3]#">

        
                                        <cfset comparray[i] = 
#Dateformat(CompletionDate, "mm/dd/yy")#>
                                        <cfset arryCntTotals[i][1] = 
arryCntTotals[i][1] + 1>
                                        <cfset arryCntTotals[i][2] = 
arryCntTotals[i][2] + 1>

                                </cfif>
                        </cfloop>
                        <cfset lastEmp = EmployeeiD>
                        <cfset lastLocation = LocationID>
                </cfloop>


~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;192386516;25150098;k

Archive: 
http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:302982
Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4

Reply via email to