Qlik Community

QlikView Scripting

Discussion Board for collaboration on QlikView Scripting.

asmithbi
Contributor II

Section Access Wildcard * Not Working

Hello,

I have the following Section Access script with the * wildcard for two people to give them access to all data in the document.  The * wildcard  is not working.  I've seen posts on this issue, but none have resolved this specific issue.

I would appreciate any assistance with this issue.  Thank you!

Section Access;
LOAD * INLINE [

     ACCESS, NTNAME, SALESREP
     ADMIN, DOMAIN\CFO, *

     USER, DOMAIN\SALESMANGER, *   
     USER, DOMAIN\SALESUPERVISOR1, SALESREP1
     USER, DOMAIN\SALESUPERVISOR2, SALESREP2

];
Section Application
;














 










 


1 Solution

Accepted Solutions
chrwolf64
Contributor III

Re: Section Access Wildcard * Not Working

A better way is to build a linked "Access Table" with a special "Access Field":

§SALESREP:

Load distinct

SALESREP,

SALESREP as §SALESREP

resident YourTableWithSalesRepField;

Load

SALESREP,

'ALL' as §SALESREP

resident §SALESREP;

Section Access;

LOAD * INLINE [

     ACCESS, NTNAME, §SALESREP

     ADMIN, DOMAIN\CFO, ALL

     USER, DOMAIN\SALESMANGER, ALL   

     USER, DOMAIN\SALESUPERVISOR1, SALESREP1

     USER, DOMAIN\SALESUPERVISOR2, SALESREP2

];

Section Application;

9 Replies
MVP
MVP

Re: Section Access Wildcard * Not Working

I assume the wild card is working as described in the HELP:

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.

Listed values are Salesrep1 and Salesrep2, so SalesManger user should see both values. What do you see?

MVP
MVP

Re: Section Access Wildcard * Not Working

if you want to give access to all data,  add an user associated to all the SALESREP

(look at Jonathan's answer here

Re: Issue with Section Access

)

prabhu0505
Valued Contributor

Re: Section Access Wildcard * Not Working

Basically you have to list all the possible values of reduction field in Section Access table. You can create dummy record for that.


Note: Instead of * leaving blank will bring all values in QV desktop but this behavior is not available on Accesspoint. So it's better to go with dummy record creation.


Section Access;
LOAD * INLINE [

    ACCESS, NTNAME, SALESREP
    ADMIN, DOMAIN\CFO, *

    USER, DOMAIN\SALESMANGER, *   
    USER, DOMAIN\SALESUPERVISOR1, SALESREP1
    USER, DOMAIN\SALESUPERVISOR2, SALESREP2

    USER, DOMAIN\DUMMY1, SALESREP3

    USER, DOMAIN\DUMMY2, SALESREP4

];
Section Application
;

chrwolf64
Contributor III

Re: Section Access Wildcard * Not Working

A better way is to build a linked "Access Table" with a special "Access Field":

§SALESREP:

Load distinct

SALESREP,

SALESREP as §SALESREP

resident YourTableWithSalesRepField;

Load

SALESREP,

'ALL' as §SALESREP

resident §SALESREP;

Section Access;

LOAD * INLINE [

     ACCESS, NTNAME, §SALESREP

     ADMIN, DOMAIN\CFO, ALL

     USER, DOMAIN\SALESMANGER, ALL   

     USER, DOMAIN\SALESUPERVISOR1, SALESREP1

     USER, DOMAIN\SALESUPERVISOR2, SALESREP2

];

Section Application;

chrwolf64
Contributor III

Re: Section Access Wildcard * Not Working

But don't forget your service user of the distribution service in your section access! He needs a "*":

Section Access;

LOAD * INLINE [

     ACCESS, NTNAME, §SALESREP

     ADMIN, DOMAIN\QVADMIN, *   

     ADMIN, DOMAIN\CFO, ALL    

     USER, DOMAIN\SALESMANGER, ALL  

     USER, DOMAIN\SALESUPERVISOR1, SALESREP1

     USER, DOMAIN\SALESUPERVISOR2, SALESREP2

];

Section Application;

asmithbi
Contributor II

Re: Section Access Wildcard * Not Working

Thank you Christian! 

asmithbi
Contributor II

Re: Section Access Wildcard * Not Working

Thank you Saravana.  I like this option for another project.  

asmithbi
Contributor II

Re: Section Access Wildcard * Not Working

swuehl, thanks for the input.  I now have a direction to follow. 

asmithbi
Contributor II

Re: Section Access Wildcard * Not Working

Thank you maxgro. I responses below did the trick. 

Community Browser