Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Oct 7, 2022 9:24:47 AM
Oct 19, 2013 5:40:32 PM
Aside from filtering data records with Section Access, I'm usually requested to filter the objects and sheets to which users have access. To be honest, I don't like to filter individual objects since this implies a lot of mainteinance and a more complex Section Access table. So I usually describe the scenario to the IT people and Key users and they always ( so far ) decide to go for the Sheets-Security option. Which in my opinion is the best alternative because it's more common to hide a complete block of information/analysis from a user than just a single KPI.
I've seen some examples like this before in the Community, however everything I've found its exemplified based on the USERID field. So, when I tried to use those examples I ran into some common errors when dealing with Section Access, and now that I've solved them I want to share a small example about how to go when using NTNAME.
Also, I want to note that there are some easier/faster alternatives to this approach. For instance you may use the MATCH() method described in this thread: Secured sheets
However if you're already using Section Access to filter data, you have too many users and/or sheets to use the MATCH() method, or if you just need to handle those privileges outside of the .qvw ( e.g. a user will maintain an excel file), you can use/reuse Section Access to accomplish this requirement.
In my example I use INLINE loads in order to allow other people to reload the app, however you could load all tables, including the SECTION ACCESS table, from xls or qvd files.
So, in order to test this example you have to do the following:
Go to the following link to get the example file:
Sheets Security with Section Access File
I hope this example is useful and don't hesitate to ask if you have any doubt regarding it.
I have a valid license but can not open the attached .qvw. Can you re-post? Thank you.
Hi Ellen,
I just realized that I had uploaded a file with Section Access enabled... sorry!
But now you should be able to open the file.
Hope it's useful.
Thank you Carlos!
Hi Carlos,
I have section access working locally. That is, when I open my qvw and enter a particular userid/password, the correct, reduced data is present in the document tables. However, all sheets are always visible. I'm using the following expression for conditional display of the tabs: vShowTab6='Y' and sum(SHEET6)>=1
The first part of the expression, vShowTab6='Y', has been working for quite a while for other purposes. Since adding the piece for section access, and sum(SHEET6)>=1, neither is working. Is there anything else I should be looking at? Do you have any idea what I may be doing wrong?
Thank you!
Hi Ellen,
Mmmm, its difficult to say just by the description, haha, it sounds like anything could be happenning, but I suggest you review the following things:
Other than that, I think it'll be easier if you share a sample of your code or even a sample app.
Regards.
Thank you for your response, Carlos. Actually, I found a #8 item to forget - disable the Settings, Documents, Security, Show all sheets and objects setting! I had been using the CTRL-SHFT-S command during development for testing some conditional show functionality and hadn't disabled the show all feature.
Wow... I didn't know about that setting. I've never used it before but it's definitely something to watch out for. So, have you solved your problems? I hope my template was useful.
Yes, and yes. Thank you!
Hi carlos.reyes.qv
Thanks for sharing us this info.
I have the following problem,
Once the QlikServer reload, it creates a qvw file to distribuite the information to all the users, so in that qvw file the Sheet level Acccess doesnt work because all user are "ADMIN". I cant understand why the distribuite document has this configuration because the original document still has the good one and if I try to open it, works
In this first pciture there are all the projects and inside mine (47. Nivel de Servicio,,,,) there is the qvw file that if I try to open locallly (no throuh website) works perfectly the Sheet level Access
In the second Picture we see the qvw file that the Qlik Server creates to distribute via Website and in that qvw file doesnt work the sheet level Access
Any thoughts?? I am totally lost ;(
Mmm, it doesn't make sense that the users profiles are "changed" due to a distribution task on the server... I've never seen that kind of behavior. As far as I've seen, the distribution task on the server will respect the user profiles as they are or exist in the Section Access table. The only thing you should concern with is to add the user that runs the Qlik Server services as an additional (ADMIN) user profile in the Section Access table, so the Server can open the file and perform the reload task... and... adding all the users you want to give access to in the distribution task user's list.