Qlik Community

Ask a Question

QlikView Scripting

Discussion Board for collaboration on QlikView Scripting.

Announcements
Qlik Highlights 2020 Giveaway! Watch, reply and have a chance to win a $200 Amazon Gift Card! Watch Video
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

OMIT multiple fields

Hi,

I am successfully protecting a particular data field (PROTECTEDFIELD1) from unauthorised access by certain users, by using section access in my script:

SECTION Access;

LOAD ACCESS,

     NTNAME,

     OMIT

FROM

[My security spreadsheet.xlsx]

(ooxml, embedded labels, table is Sheet1);

In my spreadsheet I have the following table:

ACCESSNTNAMEOMIT
ADMINMYDOMAIN\GOD_USER
USERMYDOMAIN\LOWLY_EMPLOYEEPROTECTEDFIELD1


This works fine. When logged in as LOWLY_EMPLOYEE, I can't see PROTECTEDFIELD1.

My problem is: I can't figure out how to restrict access to more than one field. Is there a particular syntax? I have tried:

  • PROTECTEDFIELD1 PROTECTEDFIELD2
  • PROTECTEDFIELD1, PROTECTEDFIELD2
  • PROTECTEDFIELD1; PROTECTEDFIELD2

Any ideas?

Thanks

1 Solution

Accepted Solutions
MVP
MVP

Just duplicate the line with stating the other field value(s):

ACCESSNTNAMEOMIT
ADMINMYDOMAIN\GOD_USER
USERMYDOMAIN\LOWLY_EMPLOYEE

PROTECTEDFIELD1

USER

MYDOMAIN\LOWLY_EMPLOYEEPROTECTEDFIELD2

View solution in original post

2 Replies
MVP
MVP

Just duplicate the line with stating the other field value(s):

ACCESSNTNAMEOMIT
ADMINMYDOMAIN\GOD_USER
USERMYDOMAIN\LOWLY_EMPLOYEE

PROTECTEDFIELD1

USER

MYDOMAIN\LOWLY_EMPLOYEEPROTECTEDFIELD2

View solution in original post

Employee
Employee

You can also link to a second table so your user table can be 1:Many without duplication.

 

User table...

ACCESS,NTNAME,OMITGROUP

 

Table with just the OMIT fields...

OMITGROUP, OMIT

 

See an example here...

https://community.qlik.com/t5/Qlik-Sense-Documents-Videos/Example-Section-Access-w-Data-Reduction-an...