Description
Converts a date string into its internal system format.
Syntax
internal = IConv(string, "D [year] [char] [E] [F] [G] [H] [I] [J] [month_format]")
Parameters
IConv (D) accepts arguments for the following parameters.
Parameter | Description | ||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
string | Must contain a date in a compatible format (refer to "E,F,G,H,I,J" below). If string is not in the correct format for the conversion, a null is returned. For a given conversion, you can enter values in a number of different ways. The day, month and year can be separated by almost nay non-numeric character. For example, the conversion"DE", string can be any of the following values:
You can enter the month as a number, an abbreviation or fully spelled out. If you spell out or abbreviate the month, you must use the exact spelling (including punctuation, if nay) in the active language set. If you do not specify a year, the year from the system clock is used. In addition, if you only specify two digits for the year: 30 to 99 are converted as 1930 to 1999 00 to 29 are converted as 2000 to 2029 | ||||||||||||||
D | Indicates a date conversion. | ||||||||||||||
year and char | The year and char options have no effect on the IConv function. These are OConv options that are allowed in the IConv function so that you can use the same specifications for both input and output conversions. | ||||||||||||||
E,F,G,H,I,J | Options that determine the order in which the system interprets the date (day, month and year).
If you enter the date in numbers, make sure you enter the date and month in the correct order for the option. For option "DE," 6/1/09 converts to 15128, while 1/6/09 converts to 14982. If you do not specify an option, and if you enter dates as numbers, option H is assumed. | ||||||||||||||
month_format | This Parameter has no effect on the IConv function. This is an OConv option that is allowed in the IConv function so you can use the same specifications for input and output conversions. |
Remarks
Internally , OpenInsight stores all dates as the number of days since December 31, 1967, which is stored as day 0 (zero).
Any date "after" December 31, 1967, is saved as a positive number, the number of days that have elapsed since that date. Any date "before" December 31, 1967, is saved as a negative number, the number of days prior to that date.