Skip to main content
Announcements
Introducing Qlik Answers: A plug-and-play, Generative AI powered RAG solution. READ ALL ABOUT IT!
cancel
Showing results for 
Search instead for 
Did you mean: 
sjar1290
Contributor II
Contributor II

Column level security with custom text

HI All,

my requirement is, 

If you Login as ADMIN, you will have all the access to all the data

Id Name Product SSN Phone Region
1 abc xyz 100 20 US East
2 dfr 123 200 30 US West

 

If you login as USER,

the table structure should be same and I should not be able to see the SSN and Phone Info and instead of blank space I need to show "No access" message

Id Name Product SSN Phone Region
1 abc xyz No Access No Access US East
2 dfr 123 No Access No Access US West

 

I can get the desired result by using a condition at the UI level, but I don't want to go in that path, because we need to educate all the app developers to write the function at the UI side for  many number of columns to restrict the access, that's going to be a hell of a challenge.

So, is there any way we write some function at the script level to display the custom text, instead of using function in UI side to display custom text? 

any help would be appreciated.

Thank you,

Raj.

Labels (1)
2 Replies
marcus_sommer

I'm not sure but I believe it won't be possible - at least not in your described way and/or without extra logic and/or extra efforts. The reason is the field-value for a certain record could have only a single value. If you want to show a user-depending value you need to query the user and to replace this value or to replace this field against another or maybe hiding the values.

An alternatively could be to implement a Section Access - Qlik Community - 1493681 which provides with OMIT a feature to remove these fields. Means these fields will be completely erased from the data-model so that you couldn't display 'no access'. Normally that's not a disadvantage else an intended behaviour to not to hint an user for the exists of restricted data.

- Marcus

SunilChauhan
Champion II
Champion II

uSe OMIT In Section access to OMIT access of

i have tried Below Script. Showing For Sunil and Hiding for Vandana

Section Access;
Load * inline[
ACCESS,USERID,OMIT
Admin,Sunil
User,Vandana,SSN
];
Star is *;
Section Application;
Load * Inline [
Id, Name, Product, SSN ,Phone, Region
1, abc ,xyz, 100 ,20 ,US, East
2, dfr ,123, 200 ,30, US ,West
];

 

Sunil Chauhan