Skip to main content
Announcements
Have questions about Qlik Connect? Join us live on April 10th, at 11 AM ET: SIGN UP NOW
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Qliksense + Section Access

Hi all,

I tryed to apply the section access system in qliksense, following this exemple :  http://help.qlik.com/en-US/sense/2.0/Subsystems/Hub/Content/Scripting/Security/dynamic-data-reductio...

I'm trying this :

section access;

LOAD * inline [

ACCESS, USERID,REDUCTION, OMIT

ADMIN, DOMAIN\ADMIN,*,

USER, DOMAIN\B, 2,NUM

USER, DOMAIN\C, 3, ALPHA

];

section application;

T1:

LOAD *,

NUM AS REDUCTION;

LOAD

Chr( RecNo()+ord('A')-1) AS ALPHA,

RecNo() AS NUM

AUTOGENERATE 8;

The reduction works well with user A and B.

But I have an issues with the user ADMIN in this code :

The user ADMIN doesn't see every record :

He can see only Num = 2 and Num=3 ... but I would like him to see ALL record from 1 to 8.

(I tried to set ACCESS to ADMIN and USER but it doesn't wokrs).

Do you know why it's doing that and how I can fix this ?

thank you,

C.

1 Solution

Accepted Solutions
Gysbert_Wassenaar

You can solve it by leaving the entry blank instead of using a star. By default * means all listed values, not all values.

Alternatively you can put this line above the section access section:

Star = '*';

That will change the default behaviour to make the * mean all values instead of all listed values.


talk is cheap, supply exceeds demand

View solution in original post

5 Replies
vincent_ardiet
Specialist
Specialist

Hi Cyrille,

If it works like in QlikView, * means all possible values declared in the section access, not all possible values in the target table.

So, you have to insert fake users in your section access with values from 1 to 8.

Regards,

Vincent

Gysbert_Wassenaar

You can solve it by leaving the entry blank instead of using a star. By default * means all listed values, not all values.

Alternatively you can put this line above the section access section:

Star = '*';

That will change the default behaviour to make the * mean all values instead of all listed values.


talk is cheap, supply exceeds demand
Not applicable
Author

Thank you both,

the empty field in REDUCTION works fine, using SET Star = '*'; with * again in reduction doesn't work ..

Inserting fake user works also, but my right are based in 5 fields (concatenated)  and there a lot and a lot of combinaisons ....

Anyway, it's working.

Thanks,

C.

vincent_ardiet
Specialist
Specialist

I think that it's not SET Star='*', but STAR is '*' the correct syntax.

But according to QlikTech this instruction is obsolete (and it doesn't work with field used as key, so not sure it works with a section access table which is used to be linked to other tables).

Regarding the number of combinations, if you build your section access at the end of your script, you just have to concatenate the existing values of your datamodel.

In your example:

section access;

LOAD * inline [

ACCESS, USERID,REDUCTION, OMIT

ADMIN, DOMAIN\ADMIN,*,

USER, DOMAIN\B, 2,NUM 

USER, DOMAIN\C, 3, ALPHA 

];

Concatenate LOAD Distinct 'USER' as ACCESS,'FAKEUSER' as USERID, REDUCTION,NUM Resident T1 ;

But if it works fine with empty value, it's less work

millan123
Creator II
Creator II

Hi,

IS there is a possibility for restrict the data by county in QMC ?