ICubeModel.LockTableForSave

Fore Syntax

LockTableForSave: Boolean;

Fore.NET Syntax

LockTableForSave: Boolean;

Description

The LockTableForSave property determines whether cube table is locked on inserting or updating data.

Comments

Available values:

The property is relevant if the repository is based on the Oracle or Microsoft SQL Server DBMS. On using the Postgres or Teradata DBMS the property is not used and tables are not locked.

Fore Example

Executing the example requires that the repository contains a cube with the StdCube identifier. A repository is based on Oracle DBMS.

Sub UserProc;
Var
    MB: IMetabase;
    Cube: ICubeModel;
Begin
    MB := MetabaseClass.Active;
    Cube := MB.ItemById(
"StdCube").Edit As ICubeModel;
    Cube.LockTableForSave := 
True;
    (Cube 
As IMetabaseObject).Save;
End Sub UserProc;

On executing the example the mode of locking the table with data on inserting or updating data will be enabled.

Fore.NET Example

The requirements and result of the Fore.NET example execution match with those in the Fore example.

Imports Prognoz.Platform.Interop.Cubes;
Imports Prognoz.Platform.Interop.Metabase;

Public Shared Sub Main(Params: StartParams);
Var
    MB: IMetabase;
    Cube: ICubeModel;
Begin
    MB := Params.Metabase;
    Cube := MB.ItemById[
"StdCube"].Edit() As ICubeModel;
    Cube.LockTableForSave := 
True;
    (Cube 
As IMetabaseObject).Save();
End Sub;

See also:

ICubeModel