Hello all... I could use a little help here. I am trying to get the latest transaction date from all users within a specified date range. But the query below is giving me records from the date range for this year and last year. What the heck am I doing wrong?
SELECT dbo.tblSubscribers.SID, dbo.tblSubscribers.Username, max(dbo.tblUserTransactionLog.Processed) FROM dbo.tblSubscribers, dbo.tblUserTransactionLog WHERE (dbo.tblSubscribers.SID = dbo.tblUserTransactionLog.SID) GROUP BY dbo.tblSubscribers.SID, dbo.tblSubscribers.Username, HAVING (CONVERT(varchar, MAX(dbo.tblUserTransactionLog.Processed),101) >= '08/01/2007') AND (CONVERT(varchar, MAX(dbo.tblUserTransactionLog.Processed),101) <= '08/07/2007') Thanks, CWB ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~| Get the answers you are looking for on the ColdFusion Labs Forum direct from active programmers and developers. http://www.adobe.com/cfusion/webforums/forum/categories.cfm?forumid-72&catid=648 Archive: http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:285720 Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4