I have the following query

<cfquery name="qryEvent" datasource="#request.ds#">
SELECT  tbl_event.Event_ID, tbl_event.Event_LocationID,
tbl_event.Event_Date, tbl_event.Event_Title,
               tbl_location.location_Name
FROM tbl_event, tbl_location
WHERE   1 = 1
      AND (tbl_event.Event_LocationID = tbl_location.location_ID
            OR  tbl_event.Event_LocationID = 1000)
      AND tbl_event.Event_date > #now()#
      AND tbl_event.Event_date < #dateadd("m",5,now())#
ORDER BY tbl_event.Event_Date ASC
</cfquery>

Returns correct data but I need to pull only the top 3 records for each of
the 13 possible tbl_Event.Event_LocationID

Is this even possible in one query?

Thanks

-Ryan

[Todays Threads] [This Message] [Subscription] [Fast Unsubscribe] [User Settings]

Reply via email to