<?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 Use the selected value as variable $::column in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/Use-the-selected-value-as-variable-column/m-p/779697#M276317</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I have to create a set analyses which uses user's selected month as variable, and sum any document not more than that month.&lt;/P&gt;&lt;P&gt;(*If user selected Nov-2014, the set analysis must sum all the past up to Nov-2014.)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;These months are quite combined master calendar, and another expression uses only the month's sum. (This is used in the accounting GL statistics.)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Let's say, user selected Dec2014. I must do sum().&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;So I have created Dual(MonthName(&lt;SPAN style="text-decoration: underline;"&gt;&lt;EM&gt;&lt;STRONG&gt;datevalue&lt;/STRONG&gt;&lt;/EM&gt;&lt;/SPAN&gt;),Num(MonthEnd(&lt;SPAN style="font-size: 13.3333330154419px; text-decoration: underline;"&gt;&lt;EM&gt;&lt;STRONG&gt;datevalue&lt;/STRONG&gt;&lt;/EM&gt;&lt;/SPAN&gt;))) as Month.&lt;/P&gt;&lt;P&gt;&lt;IMG __jive_id="77543" alt="Error 14.jpg" class="image-1 jive-image" src="/legacyfs/online/77543_Error 14.jpg" style="height: 30px; width: 620px;" /&gt;&lt;/P&gt;&lt;P&gt;I was thinking this would work:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Sum({&amp;lt;Month={"&amp;lt;=$::Month"}&amp;gt;} Value)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;But resulted value is 0.00.&lt;/P&gt;&lt;P&gt;Would you advise how I can make this work?&lt;/P&gt;&lt;P&gt;***********************&lt;/P&gt;&lt;P&gt;*Sample App is attached.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;======Loading Script=========&lt;/P&gt;&lt;P&gt;Tmp: Load * Inline [&lt;/P&gt;&lt;P&gt;datevalue, txvalue&lt;/P&gt;&lt;P&gt;15/11/2014,5&lt;/P&gt;&lt;P&gt;15/12/2014,4&lt;/P&gt;&lt;P&gt;15/01/2015,6&lt;/P&gt;&lt;P&gt;15/02/2015,5&lt;/P&gt;&lt;P&gt;];&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;NoConcatenate&lt;/P&gt;&lt;P&gt;Test: Load Dual(MonthName(datevalue),Num(MonthEnd(datevalue))) as Month,txvalue as Value Resident Tmp; Drop Table Tmp;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;======Set Analysis======&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 13.3333330154419px;"&gt;Sum({&amp;lt;Month={"&amp;lt;=$::Month"}&amp;gt;} Value)&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I appreciate for your feedback in advance.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Tue, 10 Feb 2015 16:57:10 GMT</pubDate>
    <dc:creator>atsushi_saijo</dc:creator>
    <dc:date>2015-02-10T16:57:10Z</dc:date>
    <item>
      <title>Use the selected value as variable $::column</title>
      <link>https://community.qlik.com/t5/QlikView/Use-the-selected-value-as-variable-column/m-p/779697#M276317</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I have to create a set analyses which uses user's selected month as variable, and sum any document not more than that month.&lt;/P&gt;&lt;P&gt;(*If user selected Nov-2014, the set analysis must sum all the past up to Nov-2014.)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;These months are quite combined master calendar, and another expression uses only the month's sum. (This is used in the accounting GL statistics.)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Let's say, user selected Dec2014. I must do sum().&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;So I have created Dual(MonthName(&lt;SPAN style="text-decoration: underline;"&gt;&lt;EM&gt;&lt;STRONG&gt;datevalue&lt;/STRONG&gt;&lt;/EM&gt;&lt;/SPAN&gt;),Num(MonthEnd(&lt;SPAN style="font-size: 13.3333330154419px; text-decoration: underline;"&gt;&lt;EM&gt;&lt;STRONG&gt;datevalue&lt;/STRONG&gt;&lt;/EM&gt;&lt;/SPAN&gt;))) as Month.&lt;/P&gt;&lt;P&gt;&lt;IMG __jive_id="77543" alt="Error 14.jpg" class="image-1 jive-image" src="/legacyfs/online/77543_Error 14.jpg" style="height: 30px; width: 620px;" /&gt;&lt;/P&gt;&lt;P&gt;I was thinking this would work:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Sum({&amp;lt;Month={"&amp;lt;=$::Month"}&amp;gt;} Value)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;But resulted value is 0.00.&lt;/P&gt;&lt;P&gt;Would you advise how I can make this work?&lt;/P&gt;&lt;P&gt;***********************&lt;/P&gt;&lt;P&gt;*Sample App is attached.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;======Loading Script=========&lt;/P&gt;&lt;P&gt;Tmp: Load * Inline [&lt;/P&gt;&lt;P&gt;datevalue, txvalue&lt;/P&gt;&lt;P&gt;15/11/2014,5&lt;/P&gt;&lt;P&gt;15/12/2014,4&lt;/P&gt;&lt;P&gt;15/01/2015,6&lt;/P&gt;&lt;P&gt;15/02/2015,5&lt;/P&gt;&lt;P&gt;];&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;NoConcatenate&lt;/P&gt;&lt;P&gt;Test: Load Dual(MonthName(datevalue),Num(MonthEnd(datevalue))) as Month,txvalue as Value Resident Tmp; Drop Table Tmp;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;======Set Analysis======&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 13.3333330154419px;"&gt;Sum({&amp;lt;Month={"&amp;lt;=$::Month"}&amp;gt;} Value)&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I appreciate for your feedback in advance.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 10 Feb 2015 16:57:10 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Use-the-selected-value-as-variable-column/m-p/779697#M276317</guid>
      <dc:creator>atsushi_saijo</dc:creator>
      <dc:date>2015-02-10T16:57:10Z</dc:date>
    </item>
    <item>
      <title>Re: Use the selected value as variable $::column</title>
      <link>https://community.qlik.com/t5/QlikView/Use-the-selected-value-as-variable-column/m-p/779698#M276318</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I have referenced and noted comments on:&lt;/P&gt;&lt;P&gt;&lt;A _jive_internal="true" href="https://community.qlik.com/message/711276#711276" title="http://community.qlik.com/message/711276#711276"&gt;http://community.qlik.com/message/711276#711276&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;In this example, the selector is passed as text, even if loading script has passed the value as Dual. Consequently, it seems only option we could apply is to use Document Triggers. By setting 2 actions for Month selections as below:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;IMG __jive_id="77625" alt="Error 4.jpg" class="jive-image image-2" src="/legacyfs/online/77625_Error 4.jpg" style="height: auto;" /&gt;&lt;/P&gt;&lt;P&gt;By this, we forcefully select Mth field (=numeric field ), which can be used in the set analysis:&lt;/P&gt;&lt;P&gt;&lt;IMG __jive_id="77624" alt="Error 3.jpg" class="image-1 jive-image" src="/legacyfs/online/77624_Error 3.jpg" style="height: auto;" /&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt; line-height: 1.5em;"&gt;=Sum({&amp;lt;Mth={"&amp;lt;=$(=$(vSelectMth))"},Month=&amp;gt;} Value)&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt; line-height: 1.5em;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt; line-height: 1.5em;"&gt;*&lt;SPAN style="font-size: 13.3333330154419px;"&gt;$(vSelectMth) is defined in the loading script as: &lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt; line-height: 1.5em;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; Set vSelectMth = GetFieldSelections(Mth);&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt; line-height: 1.5em;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt; line-height: 1.5em;"&gt;Test App is attached. &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt; line-height: 1.5em;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt; line-height: 1.5em;"&gt;*I will leave this post open for a while, so that smarter solution could be posted by fellow BI practitioners. &lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt; line-height: 1.5em;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 11 Feb 2015 09:44:09 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Use-the-selected-value-as-variable-column/m-p/779698#M276318</guid>
      <dc:creator>atsushi_saijo</dc:creator>
      <dc:date>2015-02-11T09:44:09Z</dc:date>
    </item>
    <item>
      <title>Re: Use the selected value as variable $::column</title>
      <link>https://community.qlik.com/t5/QlikView/Use-the-selected-value-as-variable-column/m-p/779699#M276319</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;QuickNote: It might be that I do not need any of these, but simply $(=Max(Month)) might have worked.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;**Yes, the dual value, such as MonthName() does not require any. This topic is resolved. &lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 11 Feb 2015 10:24:10 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Use-the-selected-value-as-variable-column/m-p/779699#M276319</guid>
      <dc:creator>atsushi_saijo</dc:creator>
      <dc:date>2015-02-11T10:24:10Z</dc:date>
    </item>
  </channel>
</rss>

