STRTODATE

The STRTODATE function parses the input string for date and time data according to the specified Format and outputs the results as a time and date string of type DateTime.

Input

Number of Connections: 1
InputData TypeDescription
Input1StringThe date and time string to be parsed.

Output

OutputData TypeDescription
Output1DateTimeThe date and time value parsed from the input string.

Property

NameProperty TypeDescription
Modechoice

Specifies whether the input string is formatted as a mail header value, or if it is a user-defined format.



Custom - The Format, TimeZone,and Locale are to be processed according to the user's specifications.
MailFormat - The input stream is handled using the Date field format as specified by RFC2822.
FormatString

Specifies the time pattern string. Reserved pattern letters are listed below:

SymbolMeaningPresentationExample
Gera designator(Text)AD
yyear(Number)2003
Mmonth in year(Text and Number)July and 07
dday in month(Number)10
hhour in am/pm (1-12)(Number)11
Hhour in day (0-23)(Number)0
mminute in hour(Number)45
ssecond in minute(Number)54
Smillisecond(Number)955
Eday in week(Text)Tuesday
Dday in year(Number)145
Fday of week in month(Number)2 (2nd Wed in July)
wweek in year(Number)24
Wweek in month(Number)2
aam/pm marker(Text)PM
khour in day(1-24)(Number)24
Khour in am/pm (0-11)(Number)0
ztime zone(Text)Pacific Standard Time
'escape for text(Delimiter)
''single quote(Literal)'
LocalechoiceDefines the locale. If (default) is selected, the system's default locale is used.
TimeZonechoiceSpecifies the time zone. If (default) is selected, the system's default time zone is used. If (GMT) is selected, Greenwich Mean Time is used.
WhenInvalidchoice

Specifies how processing is performed if the input stream cannot be handled according to the specified Format.



1970/01/01 - 1970/01/01 (the minimum value) is output.
Null - Null is output.
Input - The input value is output as is.
Exception - An Exception is thrown.

Topic


Example

PropertyOutput
Input 12003/04/01Formatyyyy/MM/dd2003-04-01T00:00:00.000
Locale(default)
TimeZone(default)