5 Replies Latest reply: Dec 11, 2017 11:48 AM by Andrea Gigliotti RSS

    Section Access based on user's custom properties (Qlik Sense)

    Max Mustermann

      Hi all!

      I have created a custom property called GROUP in the qmc, which can either have the value G1 or G2. I have assigned this custom property to my users, some of them have G1, others G2.

       

      My application has a dimension called DIM , which can have the values "A", "B" and "C".

       

      I want to restrict all users who are in GROUP G1 (i.e. have the custom property value G1) to view all data that is connected to DIM values "B" or "C".

      I also want to restrict all users who are in G2 to view every data that is connected to "A" or "C".

       

      I have managed to make the section access work by defining the following inline table for each user manually.

       

      section access;

      LOAD * inline [

      ACCESS, USERID, DIM, OMIT

        USER, DOMAIN1\peter, "A",

        USER, DOMAIN\max, "B",

      ... ...

      ];

      section application;

       

       

      But how can I define my behavior by means of Custom Properties?

       

      I have tried this one as shown in the qliksense help page (*) but it gives me "Access denied" to every user:

       

      section access;

      LOAD * inline [

      ACCESS, USERID, GROUP, DIM, OMIT

        USER, *, G1, "A",

        USER, *, G2, "B",

      ];

       

       

      section application;

       

      (*) http://help.qlik.com/en-US/sense/September2017/Subsystems/Hub/Content/Scripting/Security/manage-security-with-section-access.htm