Day(Date,Format)

Use Day to get the day part of a date value.

Day('01012003','DDMMYYYY')

Hour(Date,Format)

Use Hour to get the hour part of a date value.

Hour('01012003','DDMMYYYY')

Minute(Date,Format)

Use Minute to get the minute part of a date value.

Minute('01012003','DDMMYYYY')

Month(Date,Format)

Use Month to get the month part of a date value.

Month('01012003','DDMMYYYY')

Second(Date,Format)

Use Second to get the second part of a date value.

Second('01012003','DDMMYYYY')

Year(Date,Format)

Use Year to get the year part of a date value.

Year('01012003','DDMMYYYY')

DayS(Date,Format)

Use DayS to get the day part of a date value as string.

DayS('01012003','DDMMYYYY')

HourS(Date,Format)

Use HourS to get the hour part of a date value as string.

HourS('01012003','DDMMYYYY')


MinuteS(Date,Format)

Use MinuteS to get the minute part of a date value as string.

MinuteS('01012003','DDMMYYYY')

MonthS(Date,Format)

Use MonthS to get the month part of a date value as string.

MonthS('01012003','DDMMYYYY')

SecondS(Date,Format)

Use SecondS to get the second part of a date value as string.

SecondS('01012003','DDMMYYYY')

YearS(Date,Format)

Use YearS to get the year part of a date value as string.

YearS('01012003','DDMMYYYY')

IncDateS (Date,Format,ChangeType,Increment)

ChangeType: YEAR,MONTH,WEEK,DAY,HOUR,MINUTE,SECOND

Use IncDateS to Increase ChangeType part of a date value by an Increment.

IncDateS ('01012003','DDMMYYYY', 'YEAR',1)

DecDateS(Date,Format,ChangeType,Decrement)

ChangeType: YEAR,MONTH,WEEK,DAY,HOUR,MINUTE,SECOND

Use DecDateS to Decrease ChangeType part of a date value by an Decrement.

DecDateS ('01012003','DDMMYYYY', 'YEAR',1)

EncodeDate(Year,Month,Day)

EncodeDate returns a TDateTime value from the values specified as the Year, Month, and Day parameters. The year must be between 1 and 9999. Valid Month values are 1 through 12. Valid Day values are 1 through 28, 29, 30, or 31, depending on the Month value. For example, the possible Day values for month 2 (February) are 1 through 28 or 1 through 29, depending on whether or not the Year value specifies a leap year.

EncodeTime(Hour,Min,Sec,MSec)

EncodeTime encodes the given hour, minute, second, and millisecond into a TDateTime value. Valid Hour values are 0 through 23. Valid Min and Sec values are 0 through 59. Valid MSec values are 0 through 999. If the specified values are not within range, EncodeTime raises an EConvertError exception. The resulting value is a number between 0 and 1 (inclusive) that indicates the fractional part of a day given by the specified time or (if 1.0) midnight on the following day. The value 0 corresponds to midnight, 0.5 corresponds to noon, 0.75 corresponds to 6:00 pm, and so on.

DayOfWeek(D)

DayOfWeek returns the day of the week of the specified date as an integer between 1 and 7, where Sunday is the first day of the week and Saturday is the seventh.

Date

Use Date to obtain the current local date as a TDateTime value. The time portion of the value is 0 (midnight).

Time

Use Time to return the current time as a TDateTime value. The two functions are completely equivalent.

Now

Returns the current date and time.

IncMonth(D)

IncMonth returns the value of the Date parameter, incremented by NumberOfMonths months. NumberOfMonths can be negative, to return a date N months previous. If the input day of month is greater than the last day of the resulting month, the day is set to the last day of the resulting month. The time of day specified by the Date parameter is copied to the result.

IsLeapYear(D)

Call IsLeapYear to determine whether the year specified by the Year parameter is a leap year. Year specifies the calendar year. Use YearOf to obtain the value of Year for IsLeapYear from a TDateTime value.

DateToStr(D)

Use DateToStr to obtain a string representation of a date value that can be used for display purposes.

TimeToStr(D)

TimeToStr converts the Time parameter, a TDateTime value, to a string.
DateTimeToStr(D)

Converts a TDateTime value to a string.

StrToDate(S)

Call StrToDate to parse a string that specifies a date. If S does not contain a valid date, StrToDate raises an exception.

StrToTime(S)

Call StrToTime to parse a string that specifies a time value. If S does not contain a valid time, StrToTime raises an exception.

StrToDateTime(S)

Call StrToDateTime to parse a string that specifies a date and time value. If S does not contain a valid date, StrToDateTime raises an exception.

FormatDateTime(Format,DateTime)

FormatDateTime formats the TDateTime value given by DateTime using the format given by Format. See the table below for information about the supported format strings.

Next Numeric Functions

We have 231 guests and one member online