RE: minus 30

2007-09-28 Thread Orlini, Robert
1 month is fine. enddate is 20070927 (for now) and is a string: I get: 568511220 as the output -Original Message- From: Jerry Johnson [mailto:[EMAIL PROTECTED] Sent: Thursday, September 27, 2007 2:12 PM To: CF-Talk Subject: Re: minus 30 Do you want 30 days, or 1 month

RE: minus 30

2007-09-28 Thread Andrew Clark
Subject: RE: minus 30 1 month is fine. enddate is 20070927 (for now) and is a string: I get: 568511220 as the output -Original Message- From: Jerry Johnson [mailto:[EMAIL PROTECTED] Sent: Thursday, September 27, 2007 2:12 PM To: CF-Talk Subject: Re: minus 30 Do you want 30 days, or 1

minus 30

2007-09-27 Thread Orlini, Robert
Hi, How can I subtract one month (30 days) from a value? The coding I have is: CFIF #get.enddate# eq #dateformat(now(),MMDD)# Yes cfelse NO /CFIF and they equal Yes all the time. Both these values check out OK and appear as: 20070927 But I need the #dateformat(now(),MMDD)# to go

Re: minus 30

2007-09-27 Thread Jerry Johnson
CFIF #get.enddate# eq #dateformat(dateAdd(m,-1,now()),MMDD)# (you need to do the dateAdd, and then do the dateFormat, and then do the compare). (you can also look at dateCompare rather than the eq, if you want) On 9/27/07, Orlini, Robert [EMAIL PROTECTED] wrote: Hi, How can I subtract

Re: minus 30

2007-09-27 Thread Tom Chiverton
On Thursday 27 Sep 2007, [EMAIL PROTECTED] wrote: CFIF #get.enddate# eq #dateformat(dateAdd(m,-1,now()),MMDD)# Note this subtracts a month (so March 28 becomes Feb 28), which is not the same thing as subtracting 30 days. I'm not sure what it does if you try and subtract one month from March

RE: minus 30

2007-09-27 Thread Andrew Clark
I'm not sure what it does if you try and subtract one month from March 30th though. In CF 7 is gives Feb 28 Andrew -Original Message- From: Tom Chiverton [mailto:[EMAIL PROTECTED] Sent: Thursday, September 27, 2007 11:48 AM To: CF-Talk Subject: Re: minus 30 On Thursday 27 Sep 2007

RE: minus 30

2007-09-27 Thread Bobby Hartsfield
Use dateadd with -1 for the month instead of -30 for the day. ..:.:.:.:.:.:.:.:.:.:.:.:.:.:.:.:.:. Bobby Hartsfield http://acoderslife.com -Original Message- From: Orlini, Robert [mailto:[EMAIL PROTECTED] Sent: Thursday, September 27, 2007 11:24 AM To: CF-Talk Subject: minus 30 Hi

RE: minus 30

2007-09-27 Thread Bobby Hartsfield
://acoderslife.com -Original Message- From: Tom Chiverton [mailto:[EMAIL PROTECTED] Sent: Thursday, September 27, 2007 11:48 AM To: CF-Talk Subject: Re: minus 30 On Thursday 27 Sep 2007, [EMAIL PROTECTED] wrote: CFIF #get.enddate# eq #dateformat(dateAdd(m,-1,now()),MMDD)# Note this subtracts

RE: minus 30

2007-09-27 Thread Orlini, Robert
That did it! Thanks Jerry and thanks all others for thier input. I got a little from each... -Original Message- From: Jerry Johnson [mailto:[EMAIL PROTECTED] Sent: Thursday, September 27, 2007 11:31 AM To: CF-Talk Subject: Re: minus 30 CFIF #get.enddate# eq #dateformat(dateAdd(m,-1

RE: minus 30

2007-09-27 Thread Orlini, Robert
11:31 AM To: CF-Talk Subject: Re: minus 30 CFIF #get.enddate# eq #dateformat(dateAdd(m,-1,now()),MMDD)# (you need to do the dateAdd, and then do the dateFormat, and then do the compare). (you can also look at dateCompare rather than the eq, if you want) On 9/27/07, Orlini, Robert [EMAIL

RE: minus 30

2007-09-27 Thread Orlini, Robert
PROTECTED] Sent: Thursday, September 27, 2007 11:48 AM To: CF-Talk Subject: Re: minus 30 On Thursday 27 Sep 2007, [EMAIL PROTECTED] wrote: CFIF #get.enddate# eq #dateformat(dateAdd(m,-1,now()),MMDD)# Note this subtracts a month (so March 28 becomes Feb 28), which is not the same thing

Re: minus 30

2007-09-27 Thread Jerry Johnson
the endate is 9/1/2007...how can I subtract 30 days from that? That's where I got: #DateAdd(d, -30, enddate)#. -Original Message- From: Jerry Johnson [mailto:[EMAIL PROTECTED] Sent: Thursday, September 27, 2007 11:31 AM To: CF-Talk Subject: Re: minus 30 CFIF #get.enddate# eq

Re: minus 30

2007-09-27 Thread Ben Doom
20070827. I don't weant to use the now()) function because the enddate can be any day not just today. Thx. -Original Message- From: Tom Chiverton [mailto:[EMAIL PROTECTED] Sent: Thursday, September 27, 2007 11:48 AM To: CF-Talk Subject: Re: minus 30 On Thursday 27 Sep 2007