<?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: Subroutine creating dozens of variables in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/Subroutine-creating-dozens-of-variables/m-p/1454746#M794240</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I remember some years ago to read some discussions about the topic and what the technical backgrounds could be and if it should be considered as bug or not - I believe the conclusion was it's not a bug else an intended feature.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Because it's not easy to find these old postings I didn't try it yet - particularly because it's just an explanation and not a solution in your case. I think the only solution would be to drop the variables within the routine (or maybe within some additionally routines) after using them. Just &lt;STRONG&gt;var = null()&lt;/STRONG&gt;; will delete the variable (only within the script - does the variable already exists within the GUI they must be deleted there first).&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;- Marcus&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Fri, 12 Jan 2018 12:54:44 GMT</pubDate>
    <dc:creator>marcus_sommer</dc:creator>
    <dc:date>2018-01-12T12:54:44Z</dc:date>
    <item>
      <title>Subroutine creating dozens of variables</title>
      <link>https://community.qlik.com/t5/QlikView/Subroutine-creating-dozens-of-variables/m-p/1454744#M794238</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I run a subroutine in my script and pass a variable name as the input parameter.&amp;nbsp; Every time it runs, Qlik creates a new variable with the name and value equal to the input variable parameter.&amp;nbsp; I found in Qlik documentation that this is standard functionality:&lt;/P&gt;&lt;P&gt; &lt;IMG alt="subDoc.jpg" class="jive-image image-1" src="https://community.qlik.com/legacyfs/online/189796_subDoc.jpg" style="height: 239px; width: 620px;" /&gt;&lt;/P&gt;&lt;P&gt;My issue is that my QVW now has hundreds of variables and it's growing by the day.&amp;nbsp; Does anyone have any experience with this issue and how to prevent it from happening?&amp;nbsp; &lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 25 Nov 2020 16:16:04 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Subroutine-creating-dozens-of-variables/m-p/1454744#M794238</guid>
      <dc:creator>mgranillo</dc:creator>
      <dc:date>2020-11-25T16:16:04Z</dc:date>
    </item>
    <item>
      <title>Re: Subroutine creating dozens of variables</title>
      <link>https://community.qlik.com/t5/QlikView/Subroutine-creating-dozens-of-variables/m-p/1454745#M794239</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Recently ran into this, and my issue sounds the same, if I passed my subroutine the parameter 4, then it created a variable 4 and assigned the variable '4' the value =4.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Not sure if it was always this way, but when I always single quoted the variables being passed as parameters in the call statement, while making sure no quoting was used in the receiving subroutine, this issue did not occur.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I.e. pairing&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Sub MyProc(var1NoQuotes, var2NoQuotes)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Call MyProc('$(vquotedArg1)','4')&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Even though my hardcode parameter of 4 was going to the subroutine in quotes, I think by default I was still able to work it as a number, without requiring a data type conversion like Num() or Num#().&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 11 Jan 2018 23:53:38 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Subroutine-creating-dozens-of-variables/m-p/1454745#M794239</guid>
      <dc:creator>evan_kurowski</dc:creator>
      <dc:date>2018-01-11T23:53:38Z</dc:date>
    </item>
    <item>
      <title>Re: Subroutine creating dozens of variables</title>
      <link>https://community.qlik.com/t5/QlikView/Subroutine-creating-dozens-of-variables/m-p/1454746#M794240</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I remember some years ago to read some discussions about the topic and what the technical backgrounds could be and if it should be considered as bug or not - I believe the conclusion was it's not a bug else an intended feature.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Because it's not easy to find these old postings I didn't try it yet - particularly because it's just an explanation and not a solution in your case. I think the only solution would be to drop the variables within the routine (or maybe within some additionally routines) after using them. Just &lt;STRONG&gt;var = null()&lt;/STRONG&gt;; will delete the variable (only within the script - does the variable already exists within the GUI they must be deleted there first).&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;- Marcus&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 12 Jan 2018 12:54:44 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Subroutine-creating-dozens-of-variables/m-p/1454746#M794240</guid>
      <dc:creator>marcus_sommer</dc:creator>
      <dc:date>2018-01-12T12:54:44Z</dc:date>
    </item>
    <item>
      <title>Re: Subroutine creating dozens of variables</title>
      <link>https://community.qlik.com/t5/QlikView/Subroutine-creating-dozens-of-variables/m-p/1454747#M794241</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thanks Evan. This worked for me.&amp;nbsp; I never would have thought of that so thanks for taking the time to share the information.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Mike&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 12 Jan 2018 14:44:15 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Subroutine-creating-dozens-of-variables/m-p/1454747#M794241</guid>
      <dc:creator>mgranillo</dc:creator>
      <dc:date>2018-01-12T14:44:15Z</dc:date>
    </item>
  </channel>
</rss>

