<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Variable upload from excel in App Development</title>
    <link>https://community.qlik.com/t5/App-Development/Variable-upload-from-excel/m-p/2531051#M107903</link>
    <description>&lt;P&gt;Hello&amp;nbsp;&lt;a href="https://community.qlik.com/t5/user/viewprofilepage/user-id/345110"&gt;@Nikita_Ben08&lt;/a&gt;&amp;nbsp;,&amp;nbsp;&lt;/P&gt;&lt;P&gt;This is really tricky! I also had the same idea and came out whit this:&amp;nbsp;&lt;/P&gt;&lt;P&gt;You should organize your excel with a column named EXPRESSION_LABEL containing the name of your desired variable (ex vBudget) and a column EXPRESSION containing the variable expression. Load the excel into your application and call this table Expression.&lt;/P&gt;&lt;P&gt;The last point, you need to copy and run this script:&amp;nbsp;&lt;/P&gt;&lt;P&gt;For vs_RowNum = 0 to NoOfRows('Expressions')-1&lt;/P&gt;&lt;P&gt;Let vs_ExpressionLabel = Peek('EXPRESSION_LABEL', '$(vs_RowNum)', 'Expressions');&lt;/P&gt;&lt;P&gt;Let $(vs_ExpressionLabel) = Peek('EXPRESSION', '$(vs_RowNum)', 'Expressions');&lt;/P&gt;&lt;P&gt;Let vs_ExpressionLabel = Null();&lt;/P&gt;&lt;P&gt;Next vs_RowNum;&lt;BR /&gt;&lt;BR /&gt;In this way, the for cicle will generate the variables indicated by your excel.&amp;nbsp;&lt;/P&gt;&lt;P&gt;Please feel free to leave a like to this comment or accept as a solution if it helps you out!&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Wed, 17 Sep 2025 08:25:21 GMT</pubDate>
    <dc:creator>FedericoDellAcqua</dc:creator>
    <dc:date>2025-09-17T08:25:21Z</dc:date>
    <item>
      <title>Variable upload from excel</title>
      <link>https://community.qlik.com/t5/App-Development/Variable-upload-from-excel/m-p/2531037#M107900</link>
      <description>&lt;P&gt;I have one&amp;nbsp; excel with&amp;nbsp; this column how to load excel variable to Qliksense variable dummy excal&lt;/P&gt;
&lt;P&gt;vBudget&lt;/P&gt;
&lt;P&gt;sum({&amp;lt;year = {$(=max(Year))},ReportingMonth={$(=num(month(MonthEnd(max({&amp;lt;Flag_sales={1}&amp;gt;}PeriodNum)))))} ,metric = {'xtx'}&amp;gt;}Budget)/1000000000&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;vActual&lt;/P&gt;
&lt;P&gt;sum({&amp;lt;year = {$(vMaxCalenderYear)},ReportingMonth={$(vMonthNum)} ,metric = {'abc'}&amp;gt;}Actual)/1000000000&lt;BR /&gt;vMaxYear, max(Year)&lt;/P&gt;
&lt;P&gt;&lt;BR /&gt;vMonthNum,&lt;/P&gt;
&lt;P&gt;num(month(MonthEnd(max({&amp;lt;Flag_sales={1}&amp;gt;}PeriodNum))))&lt;/P&gt;</description>
      <pubDate>Wed, 17 Sep 2025 07:31:54 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Variable-upload-from-excel/m-p/2531037#M107900</guid>
      <dc:creator>Nikita_Ben08</dc:creator>
      <dc:date>2025-09-17T07:31:54Z</dc:date>
    </item>
    <item>
      <title>Re: Variable upload from excel</title>
      <link>https://community.qlik.com/t5/App-Development/Variable-upload-from-excel/m-p/2531051#M107903</link>
      <description>&lt;P&gt;Hello&amp;nbsp;&lt;a href="https://community.qlik.com/t5/user/viewprofilepage/user-id/345110"&gt;@Nikita_Ben08&lt;/a&gt;&amp;nbsp;,&amp;nbsp;&lt;/P&gt;&lt;P&gt;This is really tricky! I also had the same idea and came out whit this:&amp;nbsp;&lt;/P&gt;&lt;P&gt;You should organize your excel with a column named EXPRESSION_LABEL containing the name of your desired variable (ex vBudget) and a column EXPRESSION containing the variable expression. Load the excel into your application and call this table Expression.&lt;/P&gt;&lt;P&gt;The last point, you need to copy and run this script:&amp;nbsp;&lt;/P&gt;&lt;P&gt;For vs_RowNum = 0 to NoOfRows('Expressions')-1&lt;/P&gt;&lt;P&gt;Let vs_ExpressionLabel = Peek('EXPRESSION_LABEL', '$(vs_RowNum)', 'Expressions');&lt;/P&gt;&lt;P&gt;Let $(vs_ExpressionLabel) = Peek('EXPRESSION', '$(vs_RowNum)', 'Expressions');&lt;/P&gt;&lt;P&gt;Let vs_ExpressionLabel = Null();&lt;/P&gt;&lt;P&gt;Next vs_RowNum;&lt;BR /&gt;&lt;BR /&gt;In this way, the for cicle will generate the variables indicated by your excel.&amp;nbsp;&lt;/P&gt;&lt;P&gt;Please feel free to leave a like to this comment or accept as a solution if it helps you out!&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 17 Sep 2025 08:25:21 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Variable-upload-from-excel/m-p/2531051#M107903</guid>
      <dc:creator>FedericoDellAcqua</dc:creator>
      <dc:date>2025-09-17T08:25:21Z</dc:date>
    </item>
    <item>
      <title>Re: Variable upload from excel</title>
      <link>https://community.qlik.com/t5/App-Development/Variable-upload-from-excel/m-p/2531057#M107906</link>
      <description>&lt;P&gt;Hi ,&lt;/P&gt;
&lt;P&gt;Below is my sample excel and code&amp;nbsp;&lt;/P&gt;
&lt;DIV&gt;[SETExp_Master]:&lt;/DIV&gt;
&lt;DIV&gt;LOAD&lt;/DIV&gt;
&lt;DIV&gt;&lt;SPAN&gt; [VariableName],&lt;/SPAN&gt;&lt;/DIV&gt;
&lt;DIV&gt;&lt;SPAN&gt; [VariableValue]&lt;/SPAN&gt;&lt;/DIV&gt;
&lt;DIV&gt;&amp;nbsp;FROM [lib://AttachedFiles/ Variable&amp;nbsp; Upload.xlsx]&lt;/DIV&gt;
&lt;DIV&gt;(ooxml, embedded labels, table is sheet) Where Len(VariableName)&amp;gt;0;&lt;/DIV&gt;
&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV&gt;FOR i = 0 to NoOfRows('SETExp_Master')-1&lt;/DIV&gt;
&lt;DIV&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp;LET $(peek('VariableName', i, 'VariableName')) = peek('VariableValue', i, 'VariableName');&lt;/DIV&gt;
&lt;DIV&gt;NEXT&lt;/DIV&gt;
&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV&gt;generated output from above code&lt;/DIV&gt;
&lt;DIV&gt;=sum({&amp;lt;year = {"=max(Year)"},ReportingMonth={'=num(month(MonthEnd(max({&amp;lt;Flag_sales={1}&amp;gt;}PeriodNum))))'}, cte_metric = {'xtxi'}&amp;gt;}Budget)/1000000&lt;/DIV&gt;
&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;TABLE width="991"&gt;
&lt;TBODY&gt;
&lt;TR&gt;
&lt;TD width="64"&gt;VariableName&lt;/TD&gt;
&lt;TD width="927"&gt;VariableValue&lt;/TD&gt;
&lt;/TR&gt;
&lt;TR&gt;
&lt;TD&gt;vBudget&lt;/TD&gt;
&lt;TD&gt;sum({&amp;lt;year = {$(=max(Year))},ReportingMonth={$(=num(month(MonthEnd(max({&amp;lt;Flag_sales={1}&amp;gt;}PeriodNum)))))} ,metric = {'xtx'}&amp;gt;}Budget)/1000000000&lt;/TD&gt;
&lt;/TR&gt;
&lt;TR&gt;
&lt;TD&gt;vActual&lt;/TD&gt;
&lt;TD&gt;sum({&amp;lt;year = {$(vMaxCalenderYear)},ReportingMonth={$(vMonthNum)} ,metric = {'abc'}&amp;gt;}Actual)/1000000000&lt;/TD&gt;
&lt;/TR&gt;
&lt;TR&gt;
&lt;TD&gt;vMaxYear&lt;/TD&gt;
&lt;TD&gt;max(Year)&lt;/TD&gt;
&lt;/TR&gt;
&lt;TR&gt;
&lt;TD&gt;vMonthNum&lt;/TD&gt;
&lt;TD&gt;num(month(MonthEnd(max({&amp;lt;Flag_sales={1}&amp;gt;}PeriodNum))))&lt;/TD&gt;
&lt;/TR&gt;
&lt;/TBODY&gt;
&lt;/TABLE&gt;</description>
      <pubDate>Wed, 17 Sep 2025 08:58:54 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Variable-upload-from-excel/m-p/2531057#M107906</guid>
      <dc:creator>Nikita_Ben08</dc:creator>
      <dc:date>2025-09-17T08:58:54Z</dc:date>
    </item>
    <item>
      <title>Re: Variable upload from excel</title>
      <link>https://community.qlik.com/t5/App-Development/Variable-upload-from-excel/m-p/2531058#M107907</link>
      <description>&lt;P&gt;Below is a standard SUB we use in most of our apps. I suggest you update your spreadsheet and then&amp;nbsp;you can then load data from XLS files with structure as on picture below:&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Lech_Miszkiewicz_0-1758099451166.png" style="width: 400px;"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/183712i294D56587D98014A/image-size/medium?v=v2&amp;amp;px=400" role="button" title="Lech_Miszkiewicz_0-1758099451166.png" alt="Lech_Miszkiewicz_0-1758099451166.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;    /*  Application Variables loaded from XLS, to prevent loss due to data reduction / corruption etc
	Also enables Variables to be easily re-usable in other applications, and lookup variable values without opening app */

		TRACE ---------- Loading Application Variables ------------;

//	Sub used to allow Load of Variables from multiple sheets to allow readability in the Excel file ---
      
      	Sub LoadVariables(zSheet)
        
         	//	Load Workbook containing variable library, kept in external file due to need to keep single quote treatment simple ---
          	VariablesLoadTemp:
          	LOAD 
          		Variable, 
            	Definition
          	FROM 
            	$(vConnection)\XLS\Variable Library\$(vVarLibrary)$(vSuffix).xlsx
          		(ooxml, embedded labels, table is $(zSheet))
             ;

          //--- Convert Measure variable library into variables ---
          FOR i = 1 to NoOfRows('VariablesLoadTemp')
              LET zTempVar 		= peek( 'Variable', i - 1, 'VariablesLoadTemp' );
              LET $(zTempVar)	= Lookup('Definition','Variable','$(zTempVar)','VariablesLoadTemp');
          NEXT i

          //--- Clean Up ---
          DROP TABLE VariablesLoadTemp;
          LET i = NULL();
          LET zTempVar = NULL();

      END SUB

      CALL LoadVariables('Application');				//--- Library of Other application Variables
      CALL LoadVariables('Measures');					//--- Library of Measure Variables
      CALL LoadVariables('Colours');					//--- Library of Colours Variables&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 17 Sep 2025 08:59:53 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Variable-upload-from-excel/m-p/2531058#M107907</guid>
      <dc:creator>Lech_Miszkiewicz</dc:creator>
      <dc:date>2025-09-17T08:59:53Z</dc:date>
    </item>
    <item>
      <title>Re: Variable upload from excel</title>
      <link>https://community.qlik.com/t5/App-Development/Variable-upload-from-excel/m-p/2531071#M107912</link>
      <description>&lt;P&gt;Wow thanks, your solution actually&amp;nbsp; worked .&lt;/P&gt;
&lt;P&gt;One more question how can load below expresssion in excel. Its not able to capture&amp;nbsp;'&amp;gt;=' after&amp;nbsp; excel upload it convert this to&amp;nbsp;&amp;gt;='&amp;nbsp; (without front&amp;nbsp; single quotes)&lt;/P&gt;
&lt;P&gt;='&amp;gt;='&amp;amp; Floor(MonthEnd(YearStart(vMaxDateNum))) &amp;amp; '&amp;lt;=' &amp;amp; vMaxDateNum&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;for now i convert above as this&amp;nbsp;&lt;/P&gt;
&lt;TABLE width="562"&gt;
&lt;TBODY&gt;
&lt;TR&gt;
&lt;TD width="562"&gt;Chr(62)&amp;amp;Chr(61)&amp;amp;Floor(MonthEnd(YearStart(vMaxDateNum))) &amp;amp; '&amp;lt;=' &amp;amp; vMaxDateNum&lt;/TD&gt;
&lt;/TR&gt;
&lt;/TBODY&gt;
&lt;/TABLE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 17 Sep 2025 10:19:19 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Variable-upload-from-excel/m-p/2531071#M107912</guid>
      <dc:creator>Nikita_Ben08</dc:creator>
      <dc:date>2025-09-17T10:19:19Z</dc:date>
    </item>
    <item>
      <title>Re: Variable upload from excel</title>
      <link>https://community.qlik.com/t5/App-Development/Variable-upload-from-excel/m-p/2531081#M107916</link>
      <description>&lt;P&gt;I am not sure if I understand correctly.&lt;/P&gt;&lt;P&gt;I am assuming your issue is that value in excel cannot start with = sign or &amp;gt; sign. Solution to this is to put one single quote which excel will treat rest of your cell value as text and not as formula, so why dont you just use this in excel (see the red single quote at the beginning)&lt;/P&gt;&lt;P&gt;&lt;FONT color="#FF0000"&gt;&lt;STRONG&gt;'&lt;/STRONG&gt;&lt;/FONT&gt;&lt;SPAN&gt;&amp;gt;= Floor(MonthEnd(YearStart(vMaxDateNum))) &amp;lt;= vMaxDateNum&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Wed, 17 Sep 2025 11:12:15 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Variable-upload-from-excel/m-p/2531081#M107916</guid>
      <dc:creator>Lech_Miszkiewicz</dc:creator>
      <dc:date>2025-09-17T11:12:15Z</dc:date>
    </item>
    <item>
      <title>Re: Variable upload from excel</title>
      <link>https://community.qlik.com/t5/App-Development/Variable-upload-from-excel/m-p/2531095#M107920</link>
      <description>&lt;P&gt;Is there is any way in Qliksense to export variable .Like in Qlikview we can add all variable in Input box then send to excel. Is there is any similar way in Qliksense&lt;/P&gt;</description>
      <pubDate>Wed, 17 Sep 2025 12:39:30 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Variable-upload-from-excel/m-p/2531095#M107920</guid>
      <dc:creator>Nikita_Ben08</dc:creator>
      <dc:date>2025-09-17T12:39:30Z</dc:date>
    </item>
    <item>
      <title>Re: Variable upload from excel</title>
      <link>https://community.qlik.com/t5/App-Development/Variable-upload-from-excel/m-p/2531118#M107927</link>
      <description>&lt;P&gt;I wanted to highlight an issue I am currently facing with Qlik Sense variables. Whenever I change the value of a variable or update a formula and then republish the app, the change is reflected for a short while, but after some time it automatically rolls back to the previous formula/value.&lt;BR /&gt;For example, if there is a variable ABC with the current value of 50, and I update it to 150 and republish it from Work stream to UAT stream , it initially shows the updated value of 150. However, after refresh/publish, it reverts back to the old value of 50.&lt;BR /&gt;I checked online and noticed that other users are also experiencing similar issues with variables after the latest Qlik Sense update.&lt;BR /&gt;Do we have any solution or workaround for this,&lt;/P&gt;</description>
      <pubDate>Wed, 17 Sep 2025 14:05:21 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Variable-upload-from-excel/m-p/2531118#M107927</guid>
      <dc:creator>Nikita_Ben08</dc:creator>
      <dc:date>2025-09-17T14:05:21Z</dc:date>
    </item>
    <item>
      <title>Re: Variable upload from excel</title>
      <link>https://community.qlik.com/t5/App-Development/Variable-upload-from-excel/m-p/2531161#M107938</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.qlik.com/t5/user/viewprofilepage/user-id/345110"&gt;@Nikita_Ben08&lt;/a&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;We are getting away from the topic of this thread... but shortly:&lt;/P&gt;&lt;P&gt;Is it possible that you have some variables values stored in Bookmarks. There was a period of time when storing variable values as part of bookmark was changing and here is and explanation:&lt;A href="https://community.qlik.com/t5/Visualization-and-Usability/Upcoming-change-to-variables-in-bookmarks-and-subscriptions-in/td-p/2495563" target="_blank"&gt;https://community.qlik.com/t5/Visualization-and-Usability/Upcoming-change-to-variables-in-bookmarks-and-subscriptions-in/td-p/2495563&lt;/A&gt;&lt;/P&gt;&lt;P&gt;That could be a reason why after applying say default bookmark you could have a behaviour when variable set was changed.&lt;/P&gt;&lt;P&gt;cheers&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 17 Sep 2025 23:18:29 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Variable-upload-from-excel/m-p/2531161#M107938</guid>
      <dc:creator>Lech_Miszkiewicz</dc:creator>
      <dc:date>2025-09-17T23:18:29Z</dc:date>
    </item>
  </channel>
</rss>

