Skip to end of metadata
Go to start of metadata

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 3 Current »

Overview

Executes the given callback in isolated transaction.

void myScript.Isolated(fn: () => void)

Arguments

() => void fn
The callback to execute.

Remarks

This method is useful when you want to execute some operations in a new transaction without current transaction result.

The callback function is executed in a new isolated transaction and operations in callback is always committed even current transaction is roll backed.

When callback is throws exception current and isolated transaction is roll backs.

Example

Script.Isolated(function() {
   // Do some operations in a new transaction.
});
throw new Error('some error');
  • No labels