Extracts the following fields from a DATE value:
Informal Syntax:
SPLIT_DATE( IN, YEAR, MONTH, DATE )
Formal Syntax:
SPLIT_DATE( IN:=expression,
YEAR=>variable, MONTH=>variable, DATE=>variable )
Parameter | Type | Description |
---|---|---|
IN | DATE | The date value to split into the year, month and date. |
YEAR | REF_TO INT | The year value extracted from the input value. |
MONTH | REF_TO INT | The month value extracted from the input value. |
DATE | REF_TO INT | The date value extracted from the input value. |
None.
Example of an informal call:
VAR Year, Month, Date : INT; END_VAR SPLIT_DATE( DATE#2013-01-10-21:50:00.000, Year, Month, Date )
The variable values after the SPLIT_DATE function call will be:
Variable | Value |
---|---|
Year | INT#2013 |
Month | INT#1 |
Date | INT#10 |
IEC 61131-3 Third Edition: Table 36.5.
For other date and time functions.
For the meaning of terms used in Fernhill SCADA.