Privacera Encryption - Protect, Unprotect and Mask Data with Databricks Cluster¶
This guide explains how to use Privacera's User-Defined Functions (UDFs) to perform data protection, unprotection , and masking directly within your Databricks SQL queries.
Prerequisites¶
Before you begin, ensure the following prerequisites are met:
- A Databricks cluster is up and running.
- Ensure your Databricks environment supports Scala.
- Privacera Encryption Gateway (PEG) must be enabled and properly configured. For details, see the PEG setup documentation
- Generate the necessary system schemes within Privacera.
- The target table exists and contains valid data for protect, unprotect, or mask operations.
- A masking scheme named
TEXT_MASK
is created with the format type set toText
and an appropriate masking technique selected.
Protect Data¶
Run the following command to protect data in a column.
Unprotect Data¶
Run the following command to unprotect data in a column.
Mask Data¶
Run the following command to mask data in a column.
- Previous topic: Connector Guide