Documentation Home
MySQL 9.7 Reference Manual
Related Documentation Download this Manual
PDF (US Ltr) - 41.8Mb
PDF (A4) - 41.9Mb
Man Pages (TGZ) - 272.4Kb
Man Pages (Zip) - 378.4Kb
Info (Gzip) - 4.2Mb
Info (Zip) - 4.2Mb


MySQL 9.7 Reference Manual  /  ...  /  DROP MASKING POLICY Statement

15.1.35 DROP MASKING POLICY Statement

    DROP MASKING POLICY [IF EXISTS] mask_ssn;

DROP MASKING POLICY deletes the named masking policy from the mysql.column_masking_policies table. To use this statement, you must have the MANAGE_DATA_MASKING_POLICY privilege, and the object_policy component must be loaded. If the component is not loaded, an error occurs.

DROP MASKING POLICY accepts one policy name. If the named policy does not exist, an error occurs unless IF EXISTS is provided. With IF EXISTS, the statement succeeds with no effect.

Dropping a masking policy does not check if a table column currently refers to the policy, and does not affect statements that are already running. If a masking policy is deleted, it is not possible to access the data in a column masked by it. The masking policy must be restored to access the data. Unmasked columns in the same table are unaffected.

DROP MASKING POLICY IF EXISTS mask_password;