xdmp:strftime( $format as xs:string, $value as xs:dateTime ) as xs:string
Formats a dateTime value using POSIX strftime. This function uses
the POSIX strftime system call in the way it is implemented on each
platform. For other XQuery functions that have more functionality
(for example, for things like timezones), use one or more if the
various XQuery or XSLT standard functions such as
fn:format-dateTime
.
Parameters | |
---|---|
format | The strftime format string. |
value | The dateTime value. |
The supported format strings differ for different platforms. For the supported format strings for Windows, see the following link:
http://msdn2.microsoft.com/en-us/library/fe06s4ak(VS.80).aspx
For the supported format strings for Linux, see the following link:
http://linux.about.com/library/cmd/blcmdl3_strftime.htm
xdmp:strftime("%a, %d %b %Y %H:%M:%S", fn:current-dateTime()) => Thu, 06 Nov 2014 14:08:37
Stack Overflow: Get the most useful answers to questions from the MarkLogic community, or ask your own question.