RunInSeparatePrimary (open)
Run a function in a separate transaction
Syntax
LOADLIB "mod::system/lib/database.whlib";
VARIANT FUNCTION RunInSeparatePrimary(FUNCTION PTR func, RECORD options)Parameters
FUNCTION PTR funcFunction to invoke
RECORD optionsOptions
openprimaryIf false, doesn't open a new primary right away, only closes it if opened inside the callback (default: true)
workIf true, open and commit work (unless the function throws)
Return value
VARIANTReturn value of the function