Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
I am trying to implement Section Access on some fields.
DIVISION |
SALES |
CORPORATE |
MARKETING |
EVENTS |
MAINTENANCE |
BRANCH |
ACCOUNTS |
HR |
LEGAL |
IT |
SERVICES |
TRAVEL |
SUPPLY |
LOCAL |
SALES |
CORPORATE |
MARKETING |
EVENTS |
MAINTENANCE |
MEDICAL |
PUBLICITY |
LOCAL table is sort of a super set table of DIVISION table with two additional values
Here are my requirements:
1. I need to grant ADMINS access to all the values in 3 fields.
2. All USERS should have access to MEDICAL and PUBLICITY in LOCAL by default
3. I need some USERS to have access to SALES and CORPORATE in DIVISION
4. I need some USERS to have access to SALES in DIVISION, ACCOUNTS in BRANCH
My Credentials are based on IDs. I tried some methods but 2nd condition keeps failing if I enable other conditions. How do I achieve this?
SECTION ACCESS;
ACCESS:
LOAD * INLINE
[ACCESS,ID,DIVISION,BRANCH,LOCAL
Hi, probably you need a field that stores the combination of DIVISION and LOCAL in one field, and use section access on this combined field, so you give access to all MEDICAL y PUBLICITY combinations and just the other divisions needed, something like:
ACCESS:
LOAD * INLINE
[ACCESS,ID,LOCAL_DIVISION,BRANCH
// Give all acess to LOCAL medical and publicity
ADMIN, USERID, MEDICAL_SALES
ADMIN, USERID, MEDICAL_CORPORATE
ADMIN, USERID, MEDICAL_MARKETING
...
// add access to sales division
ADMIN, USERID, SALES_SALES
ADMIN, USERID, CORPORATE_SALES
If is this what's happing it can be also be simplified creating a single 'COMMON' value for LOCAL_DIVISION for all the values with MEDICAL or PUBLICITY as LOCAL, so only have to assign this 'COMMON' value to give access to all users to those values.
Hi @rubenmarin
I tried this. Since MEDICAL and PUBLICITY values are present only in LOCAL but not in DIVISION table, the combination is working on other values but not these two.
Hi, what I mean is combine each of values from LOCAL with each of DIVISION, not with the same value, in example:
Field1:
V1
V2
Field2:
V2
V3
CombinedField:
V1_V2
V1_V3
V2_V2
V2_V3
How do I combine different Fields from different tables? In my case, DIVISION and LOCAL are two different tables right!
Hard to say withou having some image of the model and how the tables are related.
One thing is sure: if you limit users to only access 2 values of DIVISION field, they will only see the records with relationships to those 2 values.
Okay.
Is there a way in Section Access to at least use one Field - LOCAL and provide every user access to MEDICAL and PUBLICITY and the rest of the values as Optional?
LOCAL |
SALES |
CORPORATE |
MARKETING |
EVENTS |
MAINTENANCE |
MEDICAL |
PUBLICITY |
For Example:
USER1 should have access to MEDICAL, PUBLICITY by default
USER2 should have access to MEDICAL, PUBLICITY and EVENTS
USER3 should have access to MEDICAL, PUBLICITY, and SALES, and CORPORATE
As you can see, All Users should have access to MEDICAL and PUBLICITY
Hi, there can be more than one line in secton access for each user, ecah one giving access to a different value, like:
Section Access;
LOAD * INLINE [
ACCESS, NTNAME, LOCAL
USER, USER1, MEDICAL
USER, USER1, PUBLICITY
USER, USER2, MEDICAL
USER, USER2, PUBLICITY
USER, USER2, EVENTS
];
You can also use an intermediate tble to group different access restrictions like:
LOAD * Inline [
ACCESSMODE, LOCAL
1,MEDICAL
1,PUBLICITY
2,MEDICAL
2,PUBLICITY
2,EVENTS
];
And use ACCESSMODE field instead of LOCAL field in section access.
For this we need to create a rules spread sheet for the section access. We have to maintain the ID Lists in a separate sheet. and these ids will have the access as per the conditions provided in the Rules spread sheet.
While executing in the load script , conditional rules will be applied from the rules spread sheet as listed below.
1.IDS with Admin access can see all data.
2. Medical and Publicity will have access to all the IDS
3. ID's access to only table DIVISION can access the Column SALES and Corporate .
4.ID's access to tables like BRANCH and DIVISION can access ACCOUNTS in BRANCH.
Section Access;
LOAD * INLINE [
ACCESS, NTNAME, LOCAL, Login_IN
Admin, USER1,DIVISION,
Admin, USER2, BRANCH,
Admin, USER3, LOCAL,
USER, USER_DIVISION, DIVISION,
USER, USER_BRANCH, BRANCH,
USER, USER_LOCAL, LOCAL,
USER, USER_DIVISION,BRANCH,
];
Load * Users, NTNAME ,Login_IN ...
from a1.xlsx
where Login_IN=osuser();
Assign these NT Names against the user list in the excel as a column.
Have a look at the following Design Blog post, there are two Dynamic Data Reduction links at the bottom of this one to other posts, be sure to review those as well, believe that should clarify approach to things for you:
https://community.qlik.com/t5/Qlik-Design-Blog/A-Primer-on-Section-Access/ba-p/1465766
Regards,
Brett