Blocking user access to a field using OMIT

It can sometimes happen that some fields in a document should not be seen by some users while being available to others. A classic case might be an HR document, where some users can see the list of employees but might not be able to see the Salary field.

We do this by associating the users with a field called OMIT. Now, this is QlikView, so it doesn't have to be a 1:1 association, and users can be associated with multiple OMIT values.

Getting ready

Load the following script:

Section Access; Access: LOAD * INLINE [ ACCESS, USERID, PASSWORD, OMITGROUP ADMIN, admin, admin, USER, user1, user1, USER, user2, user2, SALARYONLY USER, user3, user3, SALARYANDABSENCE USER, user4, user4, ABSENCEONLY ]; OmitGroups: LOAD ...

Get QlikView for Developers Cookbook now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.