Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 
cjmckenna
Partner - Contributor II
Partner - Contributor II

Qlik Sense section access spread across multiple QVS files

For our product, we are trying to keep the Qlik scripts in their own external files, and the report itself just references these external .qvs files. I noticed that if i break up the Section Access code from the other sections, it seems to run OK, but the results are not what I am expecting. However if I have them all in the script within the report, it is working as expected. Is it possible to have the section access code in it's own .qvs file, apart from the Section Application section?

Basically, the first file starts with :

Section Access;

...

And the next file starts with:

Section Application;

...

Labels (1)
1 Solution

Accepted Solutions
Rodj
Luminary Alumni
Luminary Alumni

As far as I know what you are describing should work, but I wonder if it would be safer to have both the section access and section application declarations in the one qvs, that way the section access is completely encapsulated in one file removing any possibility for other developers to make a potentially incorrect assumption. What unexpected results are you getting? I take it your section access isn't working properly?

Personally I'm not sure I would break out the section declarations into include files for the sake of clarity and maintainability. I think it would be safer to include them in the main script and only be embedding load logic in the called qvs files. Those section declarations are pretty key high level declarations in the context of a Qlik load script.

View solution in original post

2 Replies
Rodj
Luminary Alumni
Luminary Alumni

As far as I know what you are describing should work, but I wonder if it would be safer to have both the section access and section application declarations in the one qvs, that way the section access is completely encapsulated in one file removing any possibility for other developers to make a potentially incorrect assumption. What unexpected results are you getting? I take it your section access isn't working properly?

Personally I'm not sure I would break out the section declarations into include files for the sake of clarity and maintainability. I think it would be safer to include them in the main script and only be embedding load logic in the called qvs files. Those section declarations are pretty key high level declarations in the context of a Qlik load script.

cjmckenna
Partner - Contributor II
Partner - Contributor II
Author

Thanks for the reply! I looked into this further and the issue was not related to splitting out in separate files, but good to know that it can be done.


I was splitting it up so that it would be easy to toggle on/off section access, and to separate out different functional sections.