7 Replies Latest reply: Mar 10, 2011 2:31 PM by Miguel Angel Baeyens de Arce RSS

    Section Access Mutiple Fields

      I want to make it so USER2 can only see CANADA in AMERICA. I want USER3 to see all countries in AMERICA. So I have the following:

      Section Access;
      LOAD * INLINE [
      ACCESS, USERID, PASSWORD, REGION, COUNTRY
      ADMIN, ADMIN, ADMIN,
      USER, USER1, U1, AFRICA, *
      USER, USER2, U2, AMERICA, CANADA
      USER, USER3, U3, AMERICA, *
      USER, USER3, U3, ASIA, *
      USER, USER3, U3, ASIA, *
      ];

      For some reason USER2 can still see other countries in AMERICA. Any ideas how to stop this? Thanks.

        • Section Access Mutiple Fields
          Miguel Angel Baeyens de Arce

          Hello,

          Did you checked "Strict exclusion" in your Settings menu, Document Properties, Opening?

          Besides, note that "*" in section access doesn't mean "all values for the field" but "all listed values in section access for this field" so when you connect via client, you will see only CANADA for each user (if strict exclusion is selected so the reducion is actually taking place).

          Hope that helps.

            • Section Access Mutiple Fields

              Thanks for the reply. So that makes it seem like I'm not on the right path to accomplish what I want. I don't want USER3 to only be able to see CANADA, I want his to be able to see all countries in AMERICA. So does that mean I have to do:

              USER, USER3, U3, AMERICA, USA

              USER, USER3, U3, AMERICA, MEXICO

              and so on for all countries. I don't think the * had the result I expected it would. I thought it meant USER3 could see all in AMERICA while USER2 could only see CANADA in AMERICA.

              Is there some other way to go about this. If I have to list every combination this table is going to get very large as we have tens of thousands of users. Thanks.

                • Section Access Mutiple Fields
                  Oleg Troyansky

                  Moshe,

                  contrary to Miguel's suggestion, I don't recommend using "Strict Exclusion" (that's how people lock themselves out of their documents). Your definition of '*' should work if you link your continents and countries properly to the proper fields in Section Application.

                  If you want to post a fragment of your script, I could possibly see what might be wrong...

                  cheers,

                    • Section Access Mutiple Fields

                      my section access part (the Country field will have a name or '*' saved in it, i don't know if this is right):

                      LOAD
                      'USER' AS [ACCESS],
                      UPPER(WINDOWS_LOGON) AS NTNAME,
                      Region,
                      Country
                      FROM $(QVDPath)\Entitlement.qvd (qvd);

                      Section Application:


                      Countries:
                      LOAD
                      CountryID,
                      Country
                      FROM $(QVDPath)\Countries.qvd (qvd);

                      Regions:
                      LOAD
                      RegionID,
                      Region
                      FROM $(QVDPath)\Regions.qvd (qvd);

                      RegionCountries:
                      LOAD
                      RegionID,
                      CountryID
                      FROM $(QVDPath)\RegionCountries.qvd (qvd);

                      Sales:
                      LOAD
                      SaleID,
                      SaleAmount,
                      Country
                      FROM $(QVDPath)\Sales.qvd (qvd);

                        • Section Access Mutiple Fields
                          Miguel Angel Baeyens de Arce

                          Hello,

                          Add the bolded line, otherwise the section access won't load (it happens when data comes from QVD files, the load needs to be unoptimized, this is one way to get it):

                           


                          moshea444 wrote:LOAD
                          'USER' AS [ACCESS],
                          UPPER(WINDOWS_LOGON) AS NTNAME,
                          Region,
                          Country
                          FROM $(QVDPath)\Entitlement.qvd (qvd)
                          WHERE 1=1;


                          Hope that helps.

                           

                    • Section Access Mutiple Fields

                      I did check "Strict exclusion" with no luck.

                    • Section Access Mutiple Fields
                      Luca Jonathan Panetta

                      Hello,

                      for more information about Section Access read this Introduction to Section Access