Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hello All,
I'm writing a script to load current month from the variable in the load script in Qlik desktop, it works fine,
but the problem is even when I tried to comment the code as below it still holds the value in it.
Let vCurrentMonth = Peek('Qvd_vCurrentMonth',vRecordNo-1,'vCurrentMonth');
lib://modified_processed/$(vCurrentMonth)
//Let current month = Peek('Qvd_vCurrentMonth',vRecordNo-1,'vCurrentMonth');
I tried going to Dev tools removed the local storage, session, and cache but nothing works.
I just found this error,
Failed to clear temp storage: It was determined that certain files are unsafe for access within a Web application, or that too many calls are being made on file resources. SecurityError
Please help me to resolve this issue.
Thanks,
Santosh
This should clear the variable storage -
Let vCurrentMonth = ;
Hello Digvijay Singh,
Thanks for your response, but the problem not in the logic and I could write a null condition go with the scripting, the problem it's holding previously cache value in the system (Qlik Desktop), which needs to remove implicitly once we refresh the app, but this not happening in this case. I still tried to disabling cache in the settings, but no results
Bit confused but , as you mentioned-
"even when I tried to comment the code as below it still holds the value in it."
Just commenting won't clear the value, once the variable is created, it remains in visualization until and unless either you move NULL like I did, or you comment (like you did) as well as remove from the variable window in front end.
It's important to remember that reload clears out tables, not variables. Once a variable is defined, either by script or the variable editor, it's (nearly?) impossible to delete it. But you can set it to null as Digvijay Singh indicated.
I agree this bit confusing, I would like to follow the steps I'm working
The below code loads the variable data from the CSV file as you see below. If you follow closely I've commented my code off and it shouldn't load any data or variables data,
// $(must_include=[lib://scripts/common\SetupVariabes.qvs]);
When I open the app and run the scripts the below $(vCurrentMonth) still hold the past data. Even though I commented on the code, I should get an exception there's no data but it's not happening.
Let vCurrentMonth = Peek('Qvd_vCurrentMonth',vRecordNo-1,'vCurrentMonth');
lib://modified_processed/$(vCurrentMonth)
Is this is the last solution for us,
Let vCurrentMonth = ;
What is this below statement doing?
Have you commented this as well?
Let vCurrentMonth = Peek('Qvd_vCurrentMonth',vRecordNo-1,'vCurrentMonth');
The format of Peek statement is like - Peek(field_name[, row_no[, table_name ] ])
Do you have table name as vCurrentMonth as well? We don't keep such names for tables, Check if variable name/table names are conflicting, not sure though..
You are kind of stuck. Once a variable is defined in either version of Qlik Sense it does not go away just because you stopped using it.
You have to go into edit mode and click on the variable button and then manually remove any variables that you don't want to use any longer.
please find the below script, I don't have an issue with my script. the only problem I have is
holding the previous values. Event though the below script is commented.
// $(must_include=[lib://scripts/common\SetupVariabes.qvs]);
Load
*
FROM [lib://modified_processed/$(vCurrentYear)\$(vCurrentMonth)\$(vTableName).csv]