Operator Type:
Operator Scope of Action:
Operator Purpose:
Operator First Added:
Operator Last Altered:
Operator Has Optional Arguments:
Operator Has Newer Dot-Operator Variant:
Function [other Function type actions]
Item [operators of similar scope]
Date-time [other Date-time operators]
Baseline
As at baseline
[More on optional operator arguments]
Yes
minute(aDate[, minutesNum])
Alternatively, use Date.minute.
minute(aDate)
returns the hour element from the aDate date/time expression, which may simply be a date-type attribute value.
minute(aDate, minutesNum)
creates a new date based on the aDate expression, but in which the minute is minutesNumDate is not changed unless aDate is an attribute and the attribute is re-setting itself:
$MyDateA = minute($MyDate,14);
$MyDate is not changed
$MyDate = minute($MyDate,14);
$MyDate is changed
Examples. If $MyDate is 4 July 2009 09:30, then
$MyDateA=minute($MyDate,5);
will change $MyDate to 4 July 2009 19:05 whilst leaving $MyDate as 4 July 2009 09:30. However, if the code is self-referring:
$MyDate=minute($MyDate,5);
will change $MyDate to 4 July 2009 19:05.
Take care using the later self-referring form in a $Rule or agent as it fires every agent update cycle adding 5 minutes each time! Make sure you use a guard agent or conditional query to make the action out of scope after the first application. Or, consider using a Stamp, which only fires once per (manual) application.