Example: Logging the Denied First Insert Into a Row-Level Security-Secured Table - Advanced SQL Engine - Teradata Database

SQL Data Definition Language Syntax and Examples

Product
Advanced SQL Engine
Teradata Database
Release Number
17.05
Published
January 2021
Language
English (United States)
Last Update
2021-01-22
dita:mapPath
ncd1596241368722.ditamap
dita:ditavalPath
hoy1596145193032.ditaval
dita:id
B035-1144
lifecycle
previous
Product Category
Teradata Vantage™

This example logs the first insert into table emp_record in database secure_db when access is denied because the session does not have the OVERRIDE INSERT CONSTRAINT privilege for constraint classification_level or when the INSERT security policy UDF for the constraint permits the insert and you either specify a value for the constraint column, or do not have an assigned session constraint value for the constraint.

     BEGIN LOGGING DENIALS
     ON FIRST OVERRIDE INSERT
     FOR CONSTRAINT classification_level
     ON TABLE secure_db.emp_record;