
xdmp:user-last-login() as element(last-login)?
Returns the last-login node for the current user. If no last-login database is specified in the App Server configuration, then the empty sequence is returned.
xdmp:user-last-login()
=>
<last-login xmlns="http://marklogic.com/xdmp/last-login">
<user-id>1134406269933351074</user-id>
<last-successful-login>2008-03-19T15:41:08</last-successful-login>
<last-unsuccessful-login>2008-03-19T15:40:45</last-unsuccessful-login>
<number-unsuccessful-logins>0</number-unsuccessful-logins>
<display-last-login>true</display-last-login>
</last-login>
Stack Overflow: Get the most useful answers to questions from the MarkLogic community, or ask your own question.