Just one 'H'

#DateAdd('H', '3', Now())#

-----Original Message-----
From: Walker, Matthew [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, December 05, 2000 6:55 PM
To: CF-Talk
Subject: RE: SQL DateAdd function - how do I?


> select StartDate, this, that
> from tblName
> where StartDate between #createODBCdate(Now())# and DateAdd("d", 7,
> 'tblName.StartDate')

Here you are testing to see if StartDate is between Now and StartDate + 7
Days.

You should be testing to see if Now is between StartDate and StartDate + 7
Days.

Something like WHERE Now() BETWEEN StartDate AND DateAdd("d", 7, StartDate)
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
        Structure your ColdFusion code with Fusebox. Get the official book at 
http://www.fusionauthority.com/bkinfo.cfm

Archives: http://www.mail-archive.com/cf-talk@houseoffusion.com/
Unsubscribe: http://www.houseoffusion.com/index.cfm?sidebar=lists

Reply via email to