Updated on 2025-10-10 GMT+08:00

DROP ROW LEVEL SECURITY POLICY

Function

Deletes a row-level access control policy from a table.

Precautions

Only the table owner or administrators can delete a row-level access control policy from the table.

Syntax

1
DROP [ ROW LEVEL SECURITY ] POLICY [ IF EXISTS ] policy_name ON table_name [ CASCADE | RESTRICT ]

Parameter Description

Table 1 DROP ROW LEVEL SECURITY POLICY parameters

Parameter

Description

Value Range

IF EXISTS

Sends a notice instead of an error if the specified row-level access control policy does not exist.

-

policy_name

Specifies the name of a row-level access control policy to be deleted.

An existing name of a row-level access control policy

table_name

Specifies the name of a data table where a row-level access control policy to be deleted is located.

An existing name of the data table where a row-level access control policy is located

CASCADE/RESTRICT

Currently, no objects depend on row-level security policies. Therefore, CASCADE is equivalent to RESTRICT, and they are reserved to ensure backward compatibility.

-

Examples

Delete the row-level access control policy all_data_rls from table all_data:

1
DROP ROW LEVEL SECURITY POLICY all_data_rls ON all_data;