QuestionQ22
Secure and govern Unity Catalog objectsYou have an Azure Databricks workspace enabled for Unity Catalog that contains a managed Delta table named Sales.
Sales stores transaction data and has the following columns:
transaction_id(string)transaction_date(date)amount(decimal)
You need to implement these data-quality requirements by using table-level data-quality enforcement:
amountmust be greater than 0.transaction_idmust never be null.
Invalid records must be rejected when they are written to the Sales table.
What should you do?
- A Use a SELECT statement with WHERE conditions to validate the data before querying.
- B Create a view that filters out rows where transaction_id is null or amount is less than or equal to 0.
- C Add a NOT NULL constraint to transaction_id and a CHECK constraint to amount.
- D Configure row-level security (RLS) where transaction_id is null or amount is less than or equal to 0.
Community Discussion