Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Is this possible?
I am doing a binary load in my app.
However, when I move my app from DEV to Prod I need to load a different app id for the same app.
So I put code in my script for both. But I have to remember to manually change it when I move the app to Prod.
Is there a way in the script to identify which server I am on and automatically load the correct app id?
I tried an If statement but it didn't like that. I was also thinking using a variable. But you can't put that in front of the binary load statement.
Here is the code that I am currently using:
//DEV
Binary 'lib://QSApps/45d5cbab-2850-4633-bce1-79bb29716fad';
//PROD
//Binary 'lib://QSApps/02ff1369-8522-45f6-8241-3651623e47db';
Again, I don't know if this would work in Qlik Sense. But in our Qlikview deployment, we use mirror directories in our dev and prod environments. So the location of our Include txt file scripts are in the same relative place.
So I used 2 different txt files with the SAME NAME for my include statement.
Except the content of the txt file in my dev environment has a different binary statement within it vs the txt file in my prod environment.
So both text files would be named BINARY.txt for instance but the script within the dev one would be
Binary 'lib://QSApps/45d5cbab-2850-4633-bce1-79bb29716fad';
And the script within the prod one would be
Binary 'lib://QSApps/02ff1369-8522-45f6-8241-3651623e47db';
Ive not used it yet but something on my to do list is looking at the Qlik Deployment Framework.
QDF QlikView Getting Started Guide
It has a version for Sense and appears to touch on the deployment topic.
Regards
Andy
Can you use an Include file?
I work in Qlikview and it worked for me there.
Include statement references an txt file that has the binary statement.
What would the syntax be?
I tried this and it is not working:
If ComputerName()="QSS-1" Then $(Include=[Lib://Includes/DEV_Binary.txt]);
The text file contains the Binary statement
Again, I don't know if this would work in Qlik Sense. But in our Qlikview deployment, we use mirror directories in our dev and prod environments. So the location of our Include txt file scripts are in the same relative place.
So I used 2 different txt files with the SAME NAME for my include statement.
Except the content of the txt file in my dev environment has a different binary statement within it vs the txt file in my prod environment.
So both text files would be named BINARY.txt for instance but the script within the dev one would be
Binary 'lib://QSApps/45d5cbab-2850-4633-bce1-79bb29716fad';
And the script within the prod one would be
Binary 'lib://QSApps/02ff1369-8522-45f6-8241-3651623e47db';
This was a qlikview-case but maybe it could be adapted to qlik sense: Re: BINARY command to be constructed dynamically.
- Marcus
Brilliantly simple. I always try to replicate the environments with the same names, etc.
I tried to really over complicate this. Your suggestion is perfect and works.
Thanks