<?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: Using a variable for full set analysis string in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/Using-a-variable-for-full-set-analysis-string/m-p/655266#M674483</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Go to Variable Panel (Ctrl + Alt + V)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Puch "Add", and type "vSERVICEDATE". Then, select these variabe, and in the below text box type just:&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;{$&amp;lt;SERVICEDATE={"&amp;gt;=$(=vFromDate) &amp;lt;=$(=vToDate)"},BDT_BOOKINGSTATUS={"CONFIRMED"}&amp;gt;}&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;Do the same for vBOOKINGDATE.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;So, your expression will be:&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;=if(vDateType='Service',&lt;/P&gt;&lt;P style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;&amp;nbsp; count($(vSERVICEDATE) TOURREF),&lt;/P&gt;&lt;P style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;&amp;nbsp; &lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;count($(vBOOKINGDATE) TOURREF))&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;&lt;/P&gt;&lt;P style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;I dont recommend, before to use this, study all your expressions, because you will can't modify these Set Analysis for a particular expression. But, if you know that this exp is exacltly the same in much places, it will help !!&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Fri, 25 Jul 2014 16:33:33 GMT</pubDate>
    <dc:creator>sebastiandperei</dc:creator>
    <dc:date>2014-07-25T16:33:33Z</dc:date>
    <item>
      <title>Using a variable for full set analysis string</title>
      <link>https://community.qlik.com/t5/QlikView/Using-a-variable-for-full-set-analysis-string/m-p/655264#M674481</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I'm building a table that has a lot of set analysis work in it. An example of one of my field calculations below:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;=if(vDateType='Service',&lt;/P&gt;&lt;P&gt;&amp;nbsp; count({$&amp;lt;SERVICEDATE={"&amp;gt;=$(=vFromDate) &amp;lt;=$(=vToDate)"},BDT_BOOKINGSTATUS={"CONFIRMED"}&amp;gt;}TOURREF),&lt;/P&gt;&lt;P&gt;&amp;nbsp; count({$&amp;lt;BOOKINGDATE={"&amp;gt;=$(=vFromDate) &amp;lt;=$(=vToDate)"},BDT_BOOKINGSTATUS={"CONFIRMED"}&amp;gt;}TOURREF)&lt;/P&gt;&lt;P&gt;)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;(I have two distinct date fields per record - SERVICEDATE and BOOKINGDATE on each record of my fact table. Requirement is to be able to select a From and To date and then identify if this should apply to the SERVICEDATE or BOOKINGDATE field and build various values around that.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I'm going to be reusing this set analysis across multiple objects, so was wondering if there was anyway of capturing all the set elements&amp;nbsp; ( {$&amp;lt;SERVICEDATE={"&amp;gt;=$(=vFromDate) &amp;lt;=$(=vToDate)"},BDT_BOOKINGSTATUS={"CONFIRMED"}&amp;gt;} ) into two variables (one for SERVICEDATE, one for BOOKINGDATE). That way if I ever need to change this in the future I can change in one place to affect multiple charts etc.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Tried a few things, but just can't seem to make this work.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Rory.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 25 Jul 2014 16:21:55 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Using-a-variable-for-full-set-analysis-string/m-p/655264#M674481</guid>
      <dc:creator />
      <dc:date>2014-07-25T16:21:55Z</dc:date>
    </item>
    <item>
      <title>Re: Using a variable for full set analysis string</title>
      <link>https://community.qlik.com/t5/QlikView/Using-a-variable-for-full-set-analysis-string/m-p/655265#M674482</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Webber, Can you please post what ur variable holds the SET expression.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;It better to create this expression on the script.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 25 Jul 2014 16:30:28 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Using-a-variable-for-full-set-analysis-string/m-p/655265#M674482</guid>
      <dc:creator />
      <dc:date>2014-07-25T16:30:28Z</dc:date>
    </item>
    <item>
      <title>Re: Using a variable for full set analysis string</title>
      <link>https://community.qlik.com/t5/QlikView/Using-a-variable-for-full-set-analysis-string/m-p/655266#M674483</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Go to Variable Panel (Ctrl + Alt + V)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Puch "Add", and type "vSERVICEDATE". Then, select these variabe, and in the below text box type just:&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;{$&amp;lt;SERVICEDATE={"&amp;gt;=$(=vFromDate) &amp;lt;=$(=vToDate)"},BDT_BOOKINGSTATUS={"CONFIRMED"}&amp;gt;}&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;Do the same for vBOOKINGDATE.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;So, your expression will be:&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;=if(vDateType='Service',&lt;/P&gt;&lt;P style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;&amp;nbsp; count($(vSERVICEDATE) TOURREF),&lt;/P&gt;&lt;P style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;&amp;nbsp; &lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;count($(vBOOKINGDATE) TOURREF))&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;&lt;/P&gt;&lt;P style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;I dont recommend, before to use this, study all your expressions, because you will can't modify these Set Analysis for a particular expression. But, if you know that this exp is exacltly the same in much places, it will help !!&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 25 Jul 2014 16:33:33 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Using-a-variable-for-full-set-analysis-string/m-p/655266#M674483</guid>
      <dc:creator>sebastiandperei</dc:creator>
      <dc:date>2014-07-25T16:33:33Z</dc:date>
    </item>
    <item>
      <title>Re: Using a variable for full set analysis string</title>
      <link>https://community.qlik.com/t5/QlikView/Using-a-variable-for-full-set-analysis-string/m-p/655267#M674484</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Dathu,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Variable vConfirmedServiceDateSetCriteria holds the content: {$&amp;lt;SERVICEDATE={"&amp;gt;=$(=vFromDate) &amp;lt;=$(=vToDate)"},BDT_BOOKINGSTATUS={"CONFIRMED"}&amp;gt;}&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Variable vConfirmedBookingDateSetCriteria holds the content: {$&amp;lt;BOOKINGDATE={"&amp;gt;=$(=vFromDate) &amp;lt;=$(=vToDate)"},BDT_BOOKINGSTATUS={"CONFIRMED"}&amp;gt;}&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;My expression in my chart then reads:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;=if(vDateType='Service',&lt;/P&gt;&lt;P&gt;&amp;nbsp; sum(=$(vConfirmedServiceDateSetCriteria)SALESPRICEEUR),&lt;/P&gt;&lt;P&gt;&amp;nbsp; sum(=$(vConfirmedBookingDateSetCriteria)SALESPRICEEUR)&lt;/P&gt;&lt;P&gt;)&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 25 Jul 2014 16:34:27 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Using-a-variable-for-full-set-analysis-string/m-p/655267#M674484</guid>
      <dc:creator />
      <dc:date>2014-07-25T16:34:27Z</dc:date>
    </item>
    <item>
      <title>Re: Using a variable for full set analysis string</title>
      <link>https://community.qlik.com/t5/QlikView/Using-a-variable-for-full-set-analysis-string/m-p/655268#M674485</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thank you Sebastian! The extra =&amp;nbsp; I had in my chart expression was the issue.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 25 Jul 2014 16:35:54 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Using-a-variable-for-full-set-analysis-string/m-p/655268#M674485</guid>
      <dc:creator />
      <dc:date>2014-07-25T16:35:54Z</dc:date>
    </item>
    <item>
      <title>Re: Using a variable for full set analysis string</title>
      <link>https://community.qlik.com/t5/QlikView/Using-a-variable-for-full-set-analysis-string/m-p/655269#M674486</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Good!&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The "=" is needed if you have an expression and you want to execute it. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;So, in this case, you only use the var to replace text, not for execute any expression.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 25 Jul 2014 17:28:31 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Using-a-variable-for-full-set-analysis-string/m-p/655269#M674486</guid>
      <dc:creator>sebastiandperei</dc:creator>
      <dc:date>2014-07-25T17:28:31Z</dc:date>
    </item>
  </channel>
</rss>

