I've looked through various options in using <cfloop> to loop over dates, but I'm having trouble figuring out how to apply it to a query -- or at least my query.
The tables store data on the activity of staff members. One table for staff, another table for the transaction. So the initial query looks roughly like this: SELECT s.StaffId,s.staffName,t.transactionDate,SUM(t.NumberOfTransactions) AS Trans FROM Staff s INNER JOIN Transactions t ON s.StaffId = t.StaffId GROUP BY s.StaffId,s.staffName I would like to loop over the results and create a weekly activity output with the rows as weeks and the staffmembers in the columns. Where does the cfloop fit into all of this? does it loop the query so that it executes 1 time for each week? or does the loop apply to the query result? Thanks in advance, John ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~| Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to date Get the Free Trial http://ad.doubleclick.net/clk;207172674;29440083;f Archive: http://www.houseoffusion.com/groups/cf-newbie/message.cfm/messageid:4245 Subscription: http://www.houseoffusion.com/groups/cf-newbie/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.15
