<?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: define a simple array in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/define-a-simple-array/m-p/1689684#M593866</link>
    <description>&lt;P&gt;Hi&lt;/P&gt;&lt;P&gt;first of all, Thanks.&lt;/P&gt;&lt;P&gt;I'm trying to stroe Strings in an array and run then a for each loop for every value.&lt;/P&gt;&lt;P&gt;Dim vSpedi&lt;/P&gt;&lt;P&gt;set vSpedi = 'string1','string2','string3'&lt;/P&gt;&lt;P&gt;for each i in vSpedi&lt;/P&gt;&lt;P&gt;end for&lt;/P&gt;&lt;P&gt;I will try your proposal.&lt;/P&gt;&lt;P&gt;Thanks in advance.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Wed, 01 Apr 2020 06:12:12 GMT</pubDate>
    <dc:creator>suhle1234</dc:creator>
    <dc:date>2020-04-01T06:12:12Z</dc:date>
    <item>
      <title>define a simple array</title>
      <link>https://community.qlik.com/t5/QlikView/define-a-simple-array/m-p/1689483#M593864</link>
      <description>&lt;P&gt;Hi&lt;/P&gt;&lt;P&gt;I'm a beginner in scripting Qlik&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I want to define an array an store 3 string&amp;nbsp; in it.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;This is not working:&lt;/P&gt;&lt;P&gt;Dim vSpedi&lt;/P&gt;&lt;P&gt;'my example:&lt;BR /&gt;'set vYears = '2008','2009','2010'&lt;BR /&gt;'Then use the for each:&lt;BR /&gt;'for each y in $(vYears)&lt;BR /&gt;'statements...&lt;BR /&gt;'next&lt;/P&gt;&lt;P&gt;set vSpedi = 'string1','string2','string3'&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;What's wrong??&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thank you!&lt;/P&gt;</description>
      <pubDate>Tue, 31 Mar 2020 14:01:31 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/define-a-simple-array/m-p/1689483#M593864</guid>
      <dc:creator>suhle1234</dc:creator>
      <dc:date>2020-03-31T14:01:31Z</dc:date>
    </item>
    <item>
      <title>Re: define a simple array</title>
      <link>https://community.qlik.com/t5/QlikView/define-a-simple-array/m-p/1689510#M593865</link>
      <description>&lt;P&gt;It will be helpful if you could provide more detail on what you are trying to achieve.&amp;nbsp; &amp;nbsp;To get the&amp;nbsp;For/Next working try:&lt;/P&gt;&lt;P&gt;FOR Each&amp;nbsp;vYears&amp;nbsp; in&amp;nbsp;'2008', '2009', '2010'&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp; Statements....&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp; //You can store the String values in a table&lt;/P&gt;&lt;P&gt;Next&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 31 Mar 2020 15:21:29 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/define-a-simple-array/m-p/1689510#M593865</guid>
      <dc:creator>albertovarela</dc:creator>
      <dc:date>2020-03-31T15:21:29Z</dc:date>
    </item>
    <item>
      <title>Re: define a simple array</title>
      <link>https://community.qlik.com/t5/QlikView/define-a-simple-array/m-p/1689684#M593866</link>
      <description>&lt;P&gt;Hi&lt;/P&gt;&lt;P&gt;first of all, Thanks.&lt;/P&gt;&lt;P&gt;I'm trying to stroe Strings in an array and run then a for each loop for every value.&lt;/P&gt;&lt;P&gt;Dim vSpedi&lt;/P&gt;&lt;P&gt;set vSpedi = 'string1','string2','string3'&lt;/P&gt;&lt;P&gt;for each i in vSpedi&lt;/P&gt;&lt;P&gt;end for&lt;/P&gt;&lt;P&gt;I will try your proposal.&lt;/P&gt;&lt;P&gt;Thanks in advance.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 01 Apr 2020 06:12:12 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/define-a-simple-array/m-p/1689684#M593866</guid>
      <dc:creator>suhle1234</dc:creator>
      <dc:date>2020-04-01T06:12:12Z</dc:date>
    </item>
    <item>
      <title>Re: define a simple array</title>
      <link>https://community.qlik.com/t5/QlikView/define-a-simple-array/m-p/1689913#M593867</link>
      <description>&lt;P&gt;How about placing the values in the array using Peek() function ?&amp;nbsp; &amp;nbsp;&lt;/P&gt;&lt;P&gt;First you place your values in a table (or get distinct value from table)&lt;/P&gt;&lt;P&gt;Second, place the values you want into the array by&amp;nbsp; using CONCAT function.&amp;nbsp; The chr(39)is for an apostrophe to identify the value. The ',' is to identify how the values are separated.&lt;/P&gt;&lt;P&gt;Third, use the PEEK function to place values into variable.&lt;/P&gt;&lt;P&gt;Last, drop tables not needed.&lt;/P&gt;&lt;P&gt;Here is an example:&lt;/P&gt;&lt;P&gt;YearsTable:&lt;/P&gt;&lt;P&gt;Load * Inline&lt;/P&gt;&lt;P&gt;[Years&lt;/P&gt;&lt;P&gt;2008&lt;/P&gt;&lt;P&gt;2009&lt;/P&gt;&lt;P&gt;2010&lt;/P&gt;&lt;P&gt;];&lt;/P&gt;&lt;P&gt;LookUp:&lt;/P&gt;&lt;P&gt;Load&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp;Concat(chr(39) &amp;amp; Years&amp;amp; chr(39), ',')&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;as YearLookUp&lt;/P&gt;&lt;P&gt;Resident YearsTable;&lt;/P&gt;&lt;P&gt;Let vYears = Peek('YearLookUp',0,'LookUp');&lt;/P&gt;&lt;P&gt;Drop Tables YearsTable, LookUp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Hope this helps.&lt;/P&gt;&lt;P&gt;Pedro.&lt;/P&gt;</description>
      <pubDate>Wed, 01 Apr 2020 15:29:05 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/define-a-simple-array/m-p/1689913#M593867</guid>
      <dc:creator>piri1069</dc:creator>
      <dc:date>2020-04-01T15:29:05Z</dc:date>
    </item>
  </channel>
</rss>

