ICM 7.1 Script Functions (date and now)

Unanswered Question
Jul 26th, 2007

I have traditionally used the following formula in scripting to determine if today's date is a specific date for things such as holidays. I use this formula in an IF node.


Every time I tested it was returning a False value. In order to see what was actually being returned for both functions, I set a variable equal to the results from both and ran call tracer. What I found out was that they were returning values just 1 digit apart. I went to the routers to ensure that the date was set correctly on both machines. Anyone else ran into this? If someone is running 7.1 would you mind running this test? Of course, be sure to change the value of the date to represent the date on which you are testing.

Note... I have always used this formula in a release 6 environment with no issue.


I have this problem too.
0 votes
  • 1
  • 2
  • 3
  • 4
  • 5
Overall Rating: 0 (0 ratings)
lpezj Fri, 07/27/2007 - 01:59


I am using this formula in a 7.1(4) IPCC enviroment:


Hope this helps,

Juan Luis

jpsweeney77 Fri, 07/27/2007 - 07:41

Thanks Luis. My only problem with that is I'm still not sure if it's the NOW function or DATE function that is returning the incorrect value. If it's the DATE function than this formula leaves me in no better position. I'll give it a shot this afternoon though. At least I can then narrow it down to which function is correct. Thanks!

dchumbley Tue, 07/31/2007 - 10:53

I have a system using 7.1.5 that I just tried the following command on and it returned false also: now()=date(2007,07,31). Try using date()=date(2007,07,31) instead of now(). That is working successfully for me and what I have typically used.

Gergely Szabo Tue, 07/31/2007 - 23:30

Hello there,

actually, it is quite enough to take a look at the scripting guide :-)


Date and Time functions...

date [ (date) ]


Returns the current system date or the date portion of a given date-time value. The given date can be a floating point value (as returned by the now function), a string of the form mm/dd/yy, or three integers: yyyy, mm, dd. date (with no arguments)returns the current date. = date(2001, 7, 15) tests whether the current date is July 15,2001.


This Discussion