The SA_POLICY_ADMIN.ENABLE_TABLE_POLICY procedure re-enables the current enforcement options, labeling function, and predicate for the specified table.
The stored procedure achieves this by reapplying the row-level security predicate and DML triggers.
Applicability
This topic applies only to OceanBase Database Enterprise Edition. OceanBase Database Community Edition provides only the MySQL mode.
Syntax
SA_POLICY_ADMIN.ENABLE_TABLE_POLICY (
policy_name IN VARCHAR,
schema_name IN VARCHAR,
table_name IN VARCHAR);
Parameters
| Parameter | Description |
|---|---|
| policy_name | The policy name. You can query the POLICY_NAME and STATUS columns of the ALL_SA_POLICIES data dictionary view for existing policies. |
| schema_name | The schema containing the table. You can query the POLICY_NAME and SCHEMA_NAME columns of the ALL_SA_TABLE_POLICIES view for this schema. |
| table_name | The table in the schema named schema_name. You can query the POLICY_NAME, SCHEMA_NAME, and TABLE_NAME columns of the ALL_SA_TABLE_POLICIES view for this table. |
Examples
The following example enables shield_agent_policy for the MISSION_LIST table in the FURY schema:
BEGIN
SA_POLICY_ADMIN.ENABLE_TABLE_POLICY(
policy_name => 'shield_agent_policy',
schema_name => 'FURY',
table_name => 'MISSION_LIST');
END;
/