IDatabase.RevokeGrantedRights

Syntax

RevokeGrantedRights: Boolean;

Description

The RevokeGrantedRights property determines whether the permissions of DB user are revoked in the old scheme, at changing the name of the scheme or of the server in properties of DB.

Comments

This property is relevant if AutoAdjustRights is set to True. By default RevokeGrantedRights is set to False.

Example

Executing this example requires that the repository contains a database with the BD identifier.

Sub Main;

Var

MB: IMetabase;

MObj: IMetabaseObject;

DB: IDatabase;

Begin

MB := MetabaseClass.Active;

MObj := MB.ItemById("BD").Edit;

DB := MObj As IDatabase;

DB.LogonData.ParamValue("SERVER") := "NewTest";

DB.LogonData.ParamValue("SCHEME") := "NewTestShema";

DB.AutoAdjustRights := True;

DB.GrantCurrentRights := True;

DB.RevokeGrantedRights := True;

MObj.Save;

End Sub Main;

After executing the example, the names of server and scheme in the BD database options are changed. The permissions to access all database objects in the new scheme are automatically granted to the user at saving. The permissions in the old scheme are revoked.

See also:

IDatabase