Difference between revisions of "STOD()"
From Recital Documentation Wiki
Yvonnemilne (Talk | contribs) |
Yvonnemilne (Talk | contribs) |
||
(3 intermediate revisions by 2 users not shown) | |||
Line 1: | Line 1: | ||
− | |||
− | |||
− | |||
− | |||
==Purpose== | ==Purpose== | ||
Function to perform string to date conversion | Function to perform string to date conversion | ||
Line 12: | Line 8: | ||
==See Also== | ==See Also== | ||
− | [[CTOD()]], [[DTOS()]] | + | [[CTOD()]], [[DTOS()]], [[SET CENTURY]] |
Line 21: | Line 17: | ||
==Example== | ==Example== | ||
<code lang="recital"> | <code lang="recital"> | ||
− | + | mCdate = dtos(date()) | |
− | + | ? mCdate | |
− | + | 20130722 | |
− | ? | + | ? type("mCdate") |
− | + | C | |
− | ? type(" | + | mDdate = stod(mCdate) |
+ | ? mDdate | ||
+ | 07/22/2013 | ||
+ | ? type("mDdate") | ||
D | D | ||
</code> | </code> | ||
Line 32: | Line 31: | ||
==Products== | ==Products== | ||
− | Recital | + | Recital, Recital Server |
[[Category:Documentation]] | [[Category:Documentation]] | ||
[[Category:Functions]] | [[Category:Functions]] |
Latest revision as of 09:29, 22 July 2013
Purpose
Function to perform string to date conversion
Syntax
STOD(<expC>)
See Also
Description
The STOD() function converts the character expression <expC>, in the format "YYYYMMDD", to a date. This function needs the century included in the character string even if SET CENTURY is OFF.
Example
mCdate = dtos(date()) ? mCdate 20130722 ? type("mCdate") C mDdate = stod(mCdate) ? mDdate 07/22/2013 ? type("mDdate") D
Products
Recital, Recital Server