<?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 Assigning the contents of a variable to a table in App Development</title>
    <link>https://community.qlik.com/t5/App-Development/Assigning-the-contents-of-a-variable-to-a-table/m-p/1654804#M48936</link>
    <description>&lt;P&gt;&lt;FONT size="2"&gt;Hi&lt;BR /&gt;I have the following list of values in a table (see &lt;EM&gt;PL_Months&lt;/EM&gt;)&lt;BR /&gt;I select one of these value from a filter pane&lt;BR /&gt;The selected value is in &lt;EM&gt;vSelectedPLMonth&lt;/EM&gt; (see below)&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT size="2"&gt;I want to add this value to table PL_Choices (see below)&lt;BR /&gt;Tried everything - any suggestions?&lt;BR /&gt;Thanks&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="courier new,courier" size="1 2 3 4 5 6 7"&gt;PLMonths:&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier" size="1 2 3 4 5 6 7"&gt;LOAD * INLINE [&lt;BR /&gt;PL_Month&lt;BR /&gt;'Oct 2019'&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier" size="1 2 3 4 5 6 7"&gt;'Nov 2019'&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier" size="1 2 3 4 5 6 7"&gt;'Dec 2019'&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier" size="1 2 3 4 5 6 7"&gt;];&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;&lt;FONT face="courier new,courier" size="1 2 3 4 5 6 7"&gt;SET vSelectedPLMonth = GetFieldSelections([PL_Month]);&lt;/FONT&gt;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="courier new,courier" size="1 2 3 4 5 6 7"&gt;PL_Choices:&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier" size="1 2 3 4 5 6 7"&gt;LOAD * INLINE [&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier" size="1 2 3 4 5 6 7"&gt;PL_Choice&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier" size="1 2 3 4 5 6 7"&gt;MTD&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier" size="1 2 3 4 5 6 7"&gt;YTD&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier" size="1 2 3 4 5 6 7"&gt;'$(=vSelectedPLMonth)'&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier" size="1 2 3 4 5 6 7"&gt;];&lt;/FONT&gt;&lt;/P&gt;</description>
    <pubDate>Thu, 05 Dec 2019 22:49:23 GMT</pubDate>
    <dc:creator>alexis</dc:creator>
    <dc:date>2019-12-05T22:49:23Z</dc:date>
    <item>
      <title>Assigning the contents of a variable to a table</title>
      <link>https://community.qlik.com/t5/App-Development/Assigning-the-contents-of-a-variable-to-a-table/m-p/1654804#M48936</link>
      <description>&lt;P&gt;&lt;FONT size="2"&gt;Hi&lt;BR /&gt;I have the following list of values in a table (see &lt;EM&gt;PL_Months&lt;/EM&gt;)&lt;BR /&gt;I select one of these value from a filter pane&lt;BR /&gt;The selected value is in &lt;EM&gt;vSelectedPLMonth&lt;/EM&gt; (see below)&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT size="2"&gt;I want to add this value to table PL_Choices (see below)&lt;BR /&gt;Tried everything - any suggestions?&lt;BR /&gt;Thanks&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="courier new,courier" size="1 2 3 4 5 6 7"&gt;PLMonths:&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier" size="1 2 3 4 5 6 7"&gt;LOAD * INLINE [&lt;BR /&gt;PL_Month&lt;BR /&gt;'Oct 2019'&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier" size="1 2 3 4 5 6 7"&gt;'Nov 2019'&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier" size="1 2 3 4 5 6 7"&gt;'Dec 2019'&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier" size="1 2 3 4 5 6 7"&gt;];&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;&lt;FONT face="courier new,courier" size="1 2 3 4 5 6 7"&gt;SET vSelectedPLMonth = GetFieldSelections([PL_Month]);&lt;/FONT&gt;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="courier new,courier" size="1 2 3 4 5 6 7"&gt;PL_Choices:&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier" size="1 2 3 4 5 6 7"&gt;LOAD * INLINE [&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier" size="1 2 3 4 5 6 7"&gt;PL_Choice&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier" size="1 2 3 4 5 6 7"&gt;MTD&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier" size="1 2 3 4 5 6 7"&gt;YTD&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier" size="1 2 3 4 5 6 7"&gt;'$(=vSelectedPLMonth)'&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier" size="1 2 3 4 5 6 7"&gt;];&lt;/FONT&gt;&lt;/P&gt;</description>
      <pubDate>Thu, 05 Dec 2019 22:49:23 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Assigning-the-contents-of-a-variable-to-a-table/m-p/1654804#M48936</guid>
      <dc:creator>alexis</dc:creator>
      <dc:date>2019-12-05T22:49:23Z</dc:date>
    </item>
    <item>
      <title>Re: Assigning the contents of a variable to a table</title>
      <link>https://community.qlik.com/t5/App-Development/Assigning-the-contents-of-a-variable-to-a-table/m-p/1654813#M48938</link>
      <description>&lt;P&gt;&lt;FONT face="arial,helvetica,sans-serif" size="3"&gt;At load time GetFieldSelections would be null&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="arial,helvetica,sans-serif" size="3"&gt;To use the value of a variable in a table, syntax would be $(&lt;SPAN&gt;vSelectedPLMonth)&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="arial,helvetica,sans-serif" size="3"&gt;&lt;SPAN&gt;I think you may want the forumula?&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="arial,helvetica,sans-serif" size="3"&gt;&lt;SPAN&gt;There would be no need to put this in the load script, in your UI, you could simply use GetFieldSelections([PL_Month]) as the dimension value&amp;nbsp;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;</description>
      <pubDate>Fri, 06 Dec 2019 00:44:50 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Assigning-the-contents-of-a-variable-to-a-table/m-p/1654813#M48938</guid>
      <dc:creator>dwforest</dc:creator>
      <dc:date>2019-12-06T00:44:50Z</dc:date>
    </item>
    <item>
      <title>Re: Assigning the contents of a variable to a table</title>
      <link>https://community.qlik.com/t5/App-Development/Assigning-the-contents-of-a-variable-to-a-table/m-p/1654814#M48939</link>
      <description>&lt;P&gt;Thanks for replying&lt;/P&gt;&lt;P&gt;The second table should contain 3 values: YTD, MTD and the month selected - I don't think your suggestion achieves that as it needs to allow for the month selected to vary..&lt;/P&gt;&lt;P&gt;Thanks&lt;/P&gt;&lt;P&gt;Alexis&lt;/P&gt;</description>
      <pubDate>Fri, 06 Dec 2019 01:09:06 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Assigning-the-contents-of-a-variable-to-a-table/m-p/1654814#M48939</guid>
      <dc:creator>alexis</dc:creator>
      <dc:date>2019-12-06T01:09:06Z</dc:date>
    </item>
    <item>
      <title>Re: Assigning the contents of a variable to a table</title>
      <link>https://community.qlik.com/t5/App-Development/Assigning-the-contents-of-a-variable-to-a-table/m-p/1655153#M48961</link>
      <description>&lt;P&gt;So you need to evaluate the selection and add to a list at run time vs load time.&lt;/P&gt;&lt;P&gt;I worked a "solution" if I am understanding the need.&lt;/P&gt;&lt;P&gt;Ditch the formula in the load:&lt;/P&gt;&lt;P&gt;PLMonths:&lt;BR /&gt;LOAD * INLINE [&lt;BR /&gt;PL_Month&lt;BR /&gt;'Oct 2019'&lt;BR /&gt;'Nov 2019'&lt;BR /&gt;'Dec 2019'&lt;BR /&gt;];&lt;/P&gt;&lt;P&gt;//Add a 'place holder' CM for current month selected&lt;BR /&gt;PL_Choices:&lt;BR /&gt;LOAD * INLINE [&lt;BR /&gt;PL_Choice&lt;BR /&gt;MTD&lt;BR /&gt;YTD&lt;BR /&gt;CM&lt;BR /&gt;];&lt;/P&gt;&lt;P&gt;In the UI, where you need the values use:&lt;/P&gt;&lt;P&gt;=if(PL_Choice='CM',GetFieldSelections([PL_Month]),PL_Choice)&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 06 Dec 2019 23:09:29 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Assigning-the-contents-of-a-variable-to-a-table/m-p/1655153#M48961</guid>
      <dc:creator>dwforest</dc:creator>
      <dc:date>2019-12-06T23:09:29Z</dc:date>
    </item>
  </channel>
</rss>

