MDY() operator returns a value of the DATE data type from three comma-separated integer operands that represent the month, the day of the month, and the year.
MDY() operator takes three valid integer expressions and converts them to a single DATE format.
These three expressions must correspond with the month, day, and year elements of a calendar date:
For example,
LET my_date = MDY(12, 12, 2018)
LET my_date = MDY(06/3, 3+9, 2025-5)
LET my_date = MDY(a, b, c)
The operands must be separated by commas.
If you specify values outside the expected ranges of days and months in the calendar, the expression will be invalid and will return NULL.
If you use WHENEVER ANY ERROR CONTINUE and display status, you will learn that incorrectly specified values cause these errors:
The third operand cannot be an abbreviation for the year. For example, if you enter 18, 4GL will consider it as 18 AD and not 2018 AD.