Its probably because in SQLServer getDate() returns a full date with time information down to the millisecond.
Depending on how accurate your dates are this might be a simple fix: dateAdded BETWEEN getDate()-1 and getDate() Cheers, Sam F On 3/6/06, Richard Cooper <[EMAIL PROTECTED]> wrote: > Hi all, > > Does anyone know why this works in access but not in SQL Server > > <cfquery name="checkForView" datasource="#theDatabase#"> > SELECT viewID, views > FROM eventViews > WHERE active = '1' > AND eventID = '#theEventID#' > AND dateAdded = getdate() > </cfquery> > > > ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~| Message: http://www.houseoffusion.com/lists.cfm/link=i:4:234265 Archives: http://www.houseoffusion.com/cf_lists/threads.cfm/4 Subscription: http://www.houseoffusion.com/lists.cfm/link=s:4 Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4 Donations & Support: http://www.houseoffusion.com/tiny.cfm/54

