Loading TOC...

MarkLogic Server 11.0 Product Documentation
trgr.triggerDatabaseOnlineEvent

trgr.triggerDatabaseOnlineEvent(
   user-name as String
) as element(trgr.databaseOnlineEvent)

Summary

Returns the XML representation of a database coming online event, usable as the event parameter of trgr.createTrigger .

Parameters
user-name The user used to execute the trigger module.

Example

const trgr = require('/MarkLogic/triggers');

trgr.triggerDatabaseOnlineEvent('database-admin');

// A trigger event suitable for use with trgr.createTrigger.
// The triggering event occurs whenever a (unspecified) database
// comes online. The trigger module associated with this event
// executes as user 'database-admin'.
   

Stack Overflow iconStack Overflow: Get the most useful answers to questions from the MarkLogic community, or ask your own question.