weekendday()

Scalar. Determines if a given date/time type falls on a weekend.

Note: This function is supported in mixed case. The Event Stream Processor supports both weekendday() and weekendDay(), and considers them the same function.

Syntax

weekendday ( calendarfile, datevalue )

Parameters

calendar

A string representing the file path for a calendar file.

datevalue

A date/time type.

Usage

Determines if a date/time type value falls on a weekend. The function returns 1 if the date/time type falls on a weekend (true), or 0 otherwise (false).The function takes a string to represent the calendar path, and a date/time type as the datevalue. The function returns an integer.

Example

weekendDay('/cals/us.cal',v.TradeTime) returns 1 if the date portion of v.TradeTime falls on a weekend, and 0 otherwise.