Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi All,
I've been trying to implement section access in my application but have found an issue I couldn't resolve.
I've got two scripts I'm playing with. The first one below works perfectly fine:
LOAD * inline [
ID
1A
1B
1C
];
Section Access;
LOAD * inline [
ACCESS, NTNAME, ID
USER, name1, 1A
USER, name2, 1A
USER, name2, 1B
];
Section Application;
I have checked "initial selection based on section access" in document properties.
With this, when I log in as user 2, I see 1A and 1B and don't see 1C which is great.
Try something different:
LOAD * inline [
ID
1Aus
1Bus
1Cus
];
Section Access;
LOAD * inline [
ACCESS, NTNAME, ID
USER, name1, 1Aus
USER, name2, 1Aus
USER, name2, 1Bus
];
Section Application;
And section access doesn't work. I didn't think there would be any difference in the two examples but I'm getting different behaviour.
Thanks a lot
OK, got it working and you are right the one below doesn't work. However, one of the requirement for section access is everything has to be in upper case. So, If you change everything to upper case it works. See attached and use your login name1 etc
LOAD * inline [
ID
1Aus
1Bus
1Cus
];
Section Access;
LOAD * inline [
ACCESS, NTNAME, ID
USER, name1, 1Aus
USER, name2, 1Aus
USER, name2, 1Bus
];
Section Application;
Hi,
Take a look at the attach and see if that will help you.
Bill
Try this:
OK, got it working and you are right the one below doesn't work. However, one of the requirement for section access is everything has to be in upper case. So, If you change everything to upper case it works. See attached and use your login name1 etc
LOAD * inline [
ID
1Aus
1Bus
1Cus
];
Section Access;
LOAD * inline [
ACCESS, NTNAME, ID
USER, name1, 1Aus
USER, name2, 1Aus
USER, name2, 1Bus
];
Section Application;
Fantastic.
This isn't mentioned in the documentation as far as I am aware. Thanks a lot. But this also means I have to create a new field in my data model with the values in uppercase.
No just write function upper(fieldname) as Fieldname it will works....
HI,
That is correct, but hard to do with an inline load.
Bill
Hi,
If you look at the QlikView Reference manual you will find:
All the fields listed in Load or Select statements in the section access must be written in UPPER CASE. Any
field name containing lower case letters in the database should be converted to upper case using the upper
function, see upper(textexpression) (page 335), before being read by the Load or Select statement. However
the user ID and the password entered by the end-user opening the QlikView documents are case insensitive.
In the 11.20 SR12 manual it is on page 419.
Bill