Adding data-level security using the CSVIdentityMap macro
Let's say that a report shows the employee names by region and country. We need to implement data security in this report so that a user can see the records only for the country they belong to. There are User Groups already defined on the Cognos server (in the directory) and users are made members of appropriate groups. For this recipe, I have added my user account to a user group called Spain.
Getting ready
Open a new list report with GO Data Warehouse (query) as the package.
How to do it...
In this recipe, we will start by creating a new list report using the following steps:
Drag the appropriate columns (Country, City, and Employee name) onto the report from the Employee by Region query subject:
Go to Query Explorer and drag over a new detail filter.
Define the filter as:
[Country] in (#CSVIdentityNameList(',')#)
Run the report to test it. You will notice that a user can see only the rows of the country/countries of which he/she is a...