Difference between revisions of "SECONDS()"
Yvonne.milne (Talk | contribs) (→See Also) |
|||
(4 intermediate revisions by the same user not shown) | |||
Line 1: | Line 1: | ||
==Purpose== | ==Purpose== | ||
Function to extract seconds from a time string | Function to extract seconds from a time string | ||
− | |||
==Syntax== | ==Syntax== | ||
SECONDS([<time-string>]) | SECONDS([<time-string>]) | ||
− | |||
==See Also== | ==See Also== | ||
− | [[AMPM()]], [[CTOT()]], [[DATE()]], [[DATETIME()]], [[ELAPTIME()]], [[HOUR()]], [[HOURS()]], [[MINUTE()]], [[MINUTES()]], [[SEC()]], [[SECS()]], [[SET | + | [[AMPM()]], [[CDOW()]], [[CMONTH()]], [[CTOD()]], [[CTOT()]], [[DATE()]], [[DATETIME()]], [[DAY()]], [[DAYS()]], [[DMY()]], [[DOW()]], [[DTOA()]], [[DTOC()]], [[DTOM()]], [[DTOS()]], [[DTOT()]], [[DTOV()]], [[ELAPTIME()]], [[EMPTY()]], [[EPOCH()]], [[GOMONTH()]], [[HOUR()]], [[HOURS()]], [[ISLEAPYEAR()]], [[LEAPYEARS()]], [[LTOS()]], [[MDY()]], [[MINUTE()]], [[MINUTES()]], [[MONTH()]], [[MTOD()]], [[MTOS()]], [[QUARTER()]], [[SEC()]], [[SECS()]], [[SET CENTURY]], [[SET DATE]], [[SET EPOCH]], [[SET HOURS]], [[SET MARK]], [[SET SECONDS]], [[STOD()]], [[STOT()]], [[STR()]], [[STRFTIME()]], [[TIME()]], [[TIMEOFDAY()]], [[TIMESTAMP()]], [[TSTRING()]], [[TTOC()]], [[TTOD()]], [[TYPE()]], [[VAL()]], [[VALIDTIME()]], [[VTOD()]], [[WEEK()]], [[YEAR()]] |
− | + | ||
==Description== | ==Description== | ||
− | The SECONDS() function returns the seconds from the current time as a number. The SECONDS() function will also return the seconds from an optionally specified <time-string> | + | The SECONDS() function returns the seconds elapsed since midnight from the current system time as a number. The SECONDS() function will also return the elapsed seconds since midnight from an optionally specified <time-string>. |
+ | From Lianja v2.0 milliseconds are included for the returned current system time. | ||
==Example== | ==Example== | ||
<code lang="recital"> | <code lang="recital"> | ||
− | ? seconds("10: | + | ? seconds("10:13:21") |
− | + | 38601 | |
+ | // From Lianja v2.0 | ||
+ | ? seconds() | ||
+ | 36834.470 | ||
</code> | </code> | ||
− | |||
− | |||
− | |||
[[Category:Documentation]] | [[Category:Documentation]] | ||
[[Category:Functions]] | [[Category:Functions]] | ||
− | |||
[[Category:Date and Time Data Functions]] | [[Category:Date and Time Data Functions]] |
Latest revision as of 11:24, 7 October 2019
Contents
Purpose
Function to extract seconds from a time string
Syntax
SECONDS([<time-string>])
See Also
AMPM(), CDOW(), CMONTH(), CTOD(), CTOT(), DATE(), DATETIME(), DAY(), DAYS(), DMY(), DOW(), DTOA(), DTOC(), DTOM(), DTOS(), DTOT(), DTOV(), ELAPTIME(), EMPTY(), EPOCH(), GOMONTH(), HOUR(), HOURS(), ISLEAPYEAR(), LEAPYEARS(), LTOS(), MDY(), MINUTE(), MINUTES(), MONTH(), MTOD(), MTOS(), QUARTER(), SEC(), SECS(), SET CENTURY, SET DATE, SET EPOCH, SET HOURS, SET MARK, SET SECONDS, STOD(), STOT(), STR(), STRFTIME(), TIME(), TIMEOFDAY(), TIMESTAMP(), TSTRING(), TTOC(), TTOD(), TYPE(), VAL(), VALIDTIME(), VTOD(), WEEK(), YEAR()
Description
The SECONDS() function returns the seconds elapsed since midnight from the current system time as a number. The SECONDS() function will also return the elapsed seconds since midnight from an optionally specified <time-string>.
From Lianja v2.0 milliseconds are included for the returned current system time.
Example
? seconds("10:13:21") 38601 // From Lianja v2.0 ? seconds() 36834.470