2

I am using xdmp:document-timestamp function to get the timestamp of the most recent update that happened on this document.

Above function returns timestamp as output like: 16222984921692864.

How can I convert this timestamp 16222984921692864 to the human readable xs:dateTime?

Mads Hansen
  • 63,927
  • 12
  • 112
  • 147
DevNinja
  • 1,459
  • 7
  • 10

1 Answers1

2

We can use the xdmp:timestamp-to-wallclock function to convert timestamp to dateTime.

xdmp:timestamp-to-wallclock(16222984921692864)

returns:

2021-05-29T10:28:12.1692864
Mads Hansen
  • 63,927
  • 12
  • 112
  • 147
DevNinja
  • 1,459
  • 7
  • 10