Skip to main content
Announcements
Qlik Connect 2025: 3 days of full immersion in data, analytics, and AI. May 13-15 | Orlando, FL: Learn More
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Section Access

There are a million posts about section access and I think reading them is making me more confused.

I am trying to apply simple logic that would look like....

section Access;
LOAD ACCESS,
    
USERID,
    
PASSWORD,
    
GROUP
FROM
[..\Passwords\QV_Passwords.xlsx]
(
ooxml, embedded labels, table is CompPlan);

section application;
LOAD USERID,
    
SECURITY_DEPT
FROM
[..\Passwords\QV_Passwords.xlsx]
(
ooxml, embedded labels, table is CompPlan);

ACCESSUSERIDPASSWORDGROUPSECURITY_DEPT
ADMIN ADMIN ADMINADMIN
ADMIN M00768BMGCOMPADMIN
ADMINM01122BMGCOMPADMIN
ADMINM09849BMGCOMPADMIN
USERM09000BMGCOMPCHIEFSURGERY

The blanks in Security Department should be ALL departments.  I have tried combinations with * and 'Star is *' (which I still do not understand) but when I run the script the reduction for 'M09000' works correctly and when I sign in as an ADMIN everything is blank.

Is there a way to say ALL departments without listing out every single one (There are quite a few!)??

1 Solution

Accepted Solutions
Anonymous
Not applicable
Author

24 Replies
Not applicable
Author

I have tried *, ALL and <ANY>....

Not applicable
Author

Hi Katie,

you can create a table like below

SecurityDesc,SECURITY_DEPT

ALL,SURGERY

ALL,SURGERY

ALL,SURGERY

ALL,SURGERY

SURGERY,SURGERY

etc

and link Security Desc with Section access.

and you can use ALL in admin.this way you can solve your problem

Not applicable
Author

I tried...

USERIDSECURITY_DEPT
ADMIN ALL
M00768ALL
M01122ALL
M09849ALL
M09000SURGERY

and when I run the ap, close it and sign in everything is null.

BUT when I sign in as 'M09000' I only see SURGERY

Not applicable
Author

can you post sample qvw

Not applicable
Author

hi,

Have a look at attached sample file for section access

following is credentials

ACCESS, USERID, PASSWORD, SD

    ADMIN, A, A,ALL

    ADMIN, B, B,ALL

    ADMIN, C, C,ALL

    USER, D, D,SURGERY

Not applicable
Author

HAHA... you beat me to it!  I was in the process of building a sample.

From looking at your sample I think the answer to my question is that I will have to write out every single Security Department?

Application;
LOAD  SD,Security_Dept INLINE [
    SD, Security_Dept
    ALL, SURGERY
    ALL, OPD
    ALL,TEST
    SURGERY,SURGERY

There are many different departments and we are trying to get away from hard coding each one.  We would like to give 4 people in the organization administrative rights to EVERY department, even if a new department is added to our database.  If they are hard coded we would have to be notified of a new department and manually go in and update it each time.

PS- thanks for your help!

Anonymous
Not applicable
Author

It is hard to see what the problem is without an example.  There are no other departments in the data to see.  Anyway, two recommendations:

1. Avoid using system field (USERID in your case) as a data reduction field in section application.  Use GROUP instead.

2. It is always a good idea to use upper() function even if you know that the data is in the uppercase already.

Regards,

Michael

Nicole-Smith

If you want them to view all departments, you can give them access to *, which will automatically give them access to all.  The following is from QV documentation:

A wildcard, i. e. *, is interpreted as all (listed) values of this field, i.e. a value listed elsewhere in this table. If used in one of the system fields (USERID, PASSWORD, NTNAME or SERIAL) in a table loaded in the access section of the script, it is interpreted as all (also not listed) possible values of this field.

Not applicable
Author

hi,


instead of hard coding you can do it using script like

load

'ALL' as SD

Security_Dept

FROM

TABLE;

UNION

load

Security_Dept as SD

Security_Dept

FROM

TABLE;


it will give you all security dept with ALL as SD.