skip to main content
Corticon Studio: Rule Language Guide : Rule operator details and examples : Year
 

Try Corticon Now

Year

SYNTAX

<DateTime>.year
<Date>.year

DESCRIPTION

Returns the century/year portion of <DateTime> or <Date>. The returned value is a four digit Integer.

USAGE RESTRICTIONS

The Operators row of the table in Summary Table of Vocabulary Usage Restriction applies. No special exceptions.

RULESHEET EXAMPLE

The following Rulesheet uses .year to evaluate dateTime1 and dateOnly1 and assign the year values to integer1 and integer2, respectively.

SAMPLE TEST

A sample Ruletest provides three examples of dateTime1 and dateOnly1. Input and Output panels are shown below: