Qlik Community

QlikView Layout & Visualizations

Discussion Board for collaboration on QlikView Layout & Visualizations.

Not applicable

Enable Conditional based on the user's permissions

Colleagues, I need your assistance, please.

I have a chart with the following dimensions: Region, Client, and the measure: Sum(Sales). Each user has permissions to see clients only for some regions but can see all the sales without detail by client. Therefore, I have to hide Client dimension if selected Regions are not in his list.

For example,

user1: Canada, Russia;

user2: USA.

So, when user1 opens the chart, he is supposed to see clients only for Canada and Russia but not for USA.

Any ideas are really appreciated!

Thank you.

1 Solution

Accepted Solutions
Not applicable

Re: Enable Conditional based on the user's permissions

Thank you somenathroy!

In fact in your example, USA is not available at all for user1.

2013-03-15_1124.png

Actually, what I was looking for is the following:

usa.png

canada-russia.png

The solution is attached.

USERID, PASSWORD

som,som, All regions

User1,u1, Canada-Russia

User2,u2, USA

7 Replies
somenathroy
Contributor III

Re: Enable Conditional based on the user's permissions

Hi,

PFA..

In this application three users have been created under SECTION ACCESS as below:

USERID, PASSWORD

som,som

User1,u1

User2,u2

Regards,

Som

Not applicable

Re: Enable Conditional based on the user's permissions

Try Section Access.

SECTION ACCESS;

LOAD * INLINE [

ACCESS, USERID, PASSWORD, COUNTRY

ADMIN, ADMIN, ADMIN,

USER, USER1, U1, CANADA

USER, USER2, U2, FRANCE

USER, USER3, U3, GBR

USER, USER3, U4, USA

USER, USER3, U4, FRANCE

];

Section Application. ;

Check the Initial Data Reduction check box.

Not applicable

Re: Enable Conditional based on the user's permissions

I know how Section Access works but this will make all unrelated regions unavailable at all for them.

Re: Enable Conditional based on the user's permissions

Try this expression.

     if(QvUser() = 'User1','USA','INDIA')

Regards,

Kaushik Solanki

somenathroy
Contributor III

Re: Enable Conditional based on the user's permissions

If you go through the attached qvw file then you can find that a map table(USERID, Region) is used to map user and region. At chart expression level it is used : Sum({<USERID={'$(=QVUser())'}>}Sales). So when User1 logs in to the app, she can see only regions that are mapped to her.

And in other side Sum(Sales) shows all the sales without detail by client.

Regards,

Som

Not applicable

Re: Enable Conditional based on the user's permissions

If you want to use section access to prevent some users from seeing some detail level data but always have access to summary level data (client and region in your case), you will need to create aggregated tables. You can aggregate your data by region and give access to the aggregate data to all users.

Not applicable

Re: Enable Conditional based on the user's permissions

Thank you somenathroy!

In fact in your example, USA is not available at all for user1.

2013-03-15_1124.png

Actually, what I was looking for is the following:

usa.png

canada-russia.png

The solution is attached.

USERID, PASSWORD

som,som, All regions

User1,u1, Canada-Russia

User2,u2, USA

Community Browser