8 Replies Latest reply: Oct 25, 2012 4:25 AM by romanergakov RSS

    Section Access Based on Two Fields

    Ronnie Slate

      Is it possible to impliment section access based on two fields? I tried code below but its not working:

       

      Section ACCESS;

      LOAD

      UPPER([ACCESS]) as ACCESS,

      UPPER(ACCESS_KEY) as ACCESS_KEY,

      UPPER(ACCESS_KEY_1) as ACCESS_KEY_1,

      UPPER (NTNAME) as NTNAME

      FROM ..\Data\IS_HR_Access.xlsx (ooxml, embedded labels, table is Sheet1);

      section application;

      star is *;

       

      Any suggestions? I appreciate your time. Thanks!

       

       

       

       

       

       

       

       

       

       

       

        • Section Access Based on Two Fields
          JOSE MARIA TOS MIÑANA

          Hi,

           

          Have you seen the section access wizard in your QlikView?? You could use the inline sentence with the fields you choose and if you prefer, do the same in an excel sheet.

          I think the UPPER function is not necessary. 

          • Section Access Based on Two Fields
            veman Reddy

            Hi Siddharth,

             

            It is possible to have section access on multiple fileds. Please upload a sample application so that I can do and report it again.

             

            BR,

            Veman Reddy

              • Re: Section Access Based on Two Fields
                subin6600

                I Guess the below syntax would help you.

                 

                section Access;
                STAR is *;

                User:
                LOAD * INLINE [
                    ACCESS, NTNAME, REGION
                    ADMIN, ABC, ,
                // user whoneeds to have admin access

                    ADMIN, BCD, , // user who needsto have admin access

                    ADMIN, CDE, , // user who needs to have adminaccess

                    ADMIN, DEF, , // user who needs to have adminaccess


                          ]
                ;

                concatenate ([User])
                LOAD
                     'USER'
                as [ACCESS]
                    
                upper(trim([User ID])) as [NTNAME],
                    
                If(isnull(trim([REGION])) = 0, Upper([REGION]), ' ') as [REGION]
                     FROM
                [<Pathname>test.xlsx]
                (
                ooxml, embedded labels, table is Authorization);

                Section Application;
                Set Application_Name       = ABC Report';
                Set Developer_Contact      = 'abc';

                Set Cargotec_Contact    = 'abc';

                Set Mail                     = 'abc@abc.com;

                Set Phone                    = '+12345’;

                Set ShortDescription ='xyz;

                 

                Note*: Please remember to select the option in Settings> Document Settings> check Initial Data reduction based on section access.

                nogap.JPG

                 

                BR/Subin

                  • Re: Section Access Based on Two Fields
                    romanergakov

                    Hi All,

                     

                    I have the same question: how can I split the access by several fields (for ex. REGION and CLIENT). Here (in Correct Answer) I see access split by REGION field only (one field). What is the way to make access to different users by different (several) fields?

                     

                    For ex. I have to following table of regions/clients:

                     

                    Region     Client

                    AAA     AAA1

                    AAA     AAA2

                    BBB     BBB1

                    BBB     BBB2

                    BBB     BBB3

                    CCC     CCC1

                    CCC     CCC2

                    CCC     CCC3

                    CCC     CCC4

                     

                    And I need to give the following access (for managers - on region level and for specialists - on client level):

                     

                    User     Region     Client

                    ManagerA     AAA     *

                    SpecialistA1     AAA     AAA1

                    SpecialistA2     AAA     AAA2

                    ManagerB     BBB     *

                    SpecialistB1     BBB     BBB1

                    SpecialistB2     BBB     BBB2

                    SpecialistB3     BBB     BBB3

                    ManagerC     CCC     *

                    SpecialistC1     CCC     CCC1

                    SpecialistC2     CCC     CCC2

                    SpecialistC3     CCC     CCC3

                    SpecialistC4     CCC     CCC4

                     

                    Thanks for your help.

                     

                    Regards,

                    Roman.

                     

                    PS The table below is working (:)) but the need is not to copy each specialist's line to according manager but grant managers' access by region which includes according clients.

                     

                    User     Client

                    ManagerA     AAA1

                    ManagerA     AAA2

                    SpecialistA1     AAA1

                    SpecialistA2     AAA2

                    ManagerB     BBB1

                    ManagerB     BBB2

                    ManagerB     BBB3

                    SpecialistB1     BBB1

                    SpecialistB2     BBB2

                    SpecialistB3     BBB3

                    ManagerC     CCC1

                    ManagerC     CCC2

                    ManagerC     CCC3

                    ManagerC     CCC4

                    SpecialistC1     CCC1

                    SpecialistC2     CCC2

                    SpecialistC3     CCC3

                    SpecialistC4     CCC4

                     

                    Message was edited by: romanergakov