17.07.2015 Views

Download eBook (PDF) - Red Gate Software

Download eBook (PDF) - Red Gate Software

Download eBook (PDF) - Red Gate Software

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

2 – Data Classification and RolesThe arguments to this system stored procedure are:• Property Name: The textual reference of the extended property tobe created.• Property Value: The value that is to be associated with the newextended property.• Object Level: The object hierarchy that defines the databaseobjects with which the extended property is associated. In our sampledatabase, we are interested in assigning the extended properties to thecolumns within the tables. The hierarchy for a column is the schema,the table and finally the column itself.In our HomeLending database, we will execute the script shown in Listing 2-8. This will create the Sensitivity_Class extended property for theBorrower_FName column in the Borrower_Name table, which contains theborrower names. This script will assign the value of "Medium"; thusdocumenting the column's sensitivity class:Please note that in order to successfully execute this system stored procedureyou will need to have ownership or ALTER or CONTROL permissions to thedatabase objects, in this case a table, in which the extended property is beingadded.USE HomeLending;GOEXEC sp_addextendedproperty@name='Sensitivity_Class',@value='Medium',@level0type='SCHEMA',@level0name='dbo',@level1type='TABLE',@level1name='Borrower_Name',@level2type='COLUMN',@level2name='Borrower_FName';GOListing 2-8: Assigning the medium sensitivity data classification to theBorrower_FName column.Executing this stored procedure on a per-column basis is probably no quickerthan using the navigable features of the Object Explorer in SQL ServerManagement Studio.However, armed with the knowledge that our default sensitivity class in oursample database is "Medium", we can construct a query, using the54

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!