You need a group by and an aggregate function:
SELECT DISTINCT e.createdByUserID,i.itemID, i.title,
max(e.datecreated)
FROM events e
JOIN v_items i ON e.itemID = i.itemID
WHERE e.createdbyuserid = 92
GROUP BY e.createdByUserID, i.itemID, i.title
ORDER BY e.datecreated desc
Rick
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Introducing the Fusion Authority Quarterly Update. 80 pages of hard-hitting,
up-to-date ColdFusion information by your peers, delivered to your door four
times a year.
http://www.fusionauthority.com/quarterly
Archive:
http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:260665
Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4