<?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 Set analysis issue. in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/Set-analysis-issue/m-p/514231#M192095</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I have a data where suppose there is actual_date, customer,&lt;/P&gt;&lt;P&gt;I also have other table where start date and complete date is present for every customer.&lt;/P&gt;&lt;P&gt;I have a common calendar also,&lt;/P&gt;&lt;P&gt;Now in a chart,&lt;/P&gt;&lt;P&gt;I need month as dimension(common month) and expression should be based on following condition.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;count(customer) when,&lt;/P&gt;&lt;P&gt;actual_date &amp;gt;= monthstart(common month) and actual_date&amp;lt;(monthend(common month))&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;this type of more conditions are there...&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Here I achieved the correct values of expression by using nested if conditions, but issue is as I am having very large amount of data , so performance issues are there.&lt;/P&gt;&lt;P&gt;Therefore I want to migrate it to set analysis.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I used&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;count({$&amp;lt;actual_date={"&amp;gt;=$(=monthstart(min(common date))) &amp;lt;$(=monthend(min(common date)))"}&amp;gt;}distinct customer).&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;but by using it I am not able to achieve correct value.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Please help me out how to get correct values.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;P&gt;Nitin&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Fri, 20 Dec 2013 11:32:37 GMT</pubDate>
    <dc:creator>Anonymous</dc:creator>
    <dc:date>2013-12-20T11:32:37Z</dc:date>
    <item>
      <title>Set analysis issue.</title>
      <link>https://community.qlik.com/t5/QlikView/Set-analysis-issue/m-p/514231#M192095</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I have a data where suppose there is actual_date, customer,&lt;/P&gt;&lt;P&gt;I also have other table where start date and complete date is present for every customer.&lt;/P&gt;&lt;P&gt;I have a common calendar also,&lt;/P&gt;&lt;P&gt;Now in a chart,&lt;/P&gt;&lt;P&gt;I need month as dimension(common month) and expression should be based on following condition.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;count(customer) when,&lt;/P&gt;&lt;P&gt;actual_date &amp;gt;= monthstart(common month) and actual_date&amp;lt;(monthend(common month))&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;this type of more conditions are there...&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Here I achieved the correct values of expression by using nested if conditions, but issue is as I am having very large amount of data , so performance issues are there.&lt;/P&gt;&lt;P&gt;Therefore I want to migrate it to set analysis.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I used&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;count({$&amp;lt;actual_date={"&amp;gt;=$(=monthstart(min(common date))) &amp;lt;$(=monthend(min(common date)))"}&amp;gt;}distinct customer).&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;but by using it I am not able to achieve correct value.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Please help me out how to get correct values.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;P&gt;Nitin&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 20 Dec 2013 11:32:37 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Set-analysis-issue/m-p/514231#M192095</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2013-12-20T11:32:37Z</dc:date>
    </item>
    <item>
      <title>Re: Set analysis issue.</title>
      <link>https://community.qlik.com/t5/QlikView/Set-analysis-issue/m-p/514232#M192096</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;can you try this.&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;&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;count({$&amp;lt;actual_date={"&amp;gt;=$(=monthstart(min(common date)))}, &lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;actual_date={"&lt;/SPAN&gt;&amp;lt;$(=monthend(min(common date)))"}&amp;gt;}distinct customer).&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 20 Dec 2013 11:36:06 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Set-analysis-issue/m-p/514232#M192096</guid>
      <dc:creator />
      <dc:date>2013-12-20T11:36:06Z</dc:date>
    </item>
    <item>
      <title>Re: Set analysis issue.</title>
      <link>https://community.qlik.com/t5/QlikView/Set-analysis-issue/m-p/514233#M192097</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;Min function will give you always min date in selection, both side.&lt;/P&gt;&lt;P style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;try below:&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;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;count({$&amp;lt;actual_date={"&amp;gt;=$(=monthstart(Min(commondate)))}, &lt;/SPAN&gt;&lt;SPAN style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;actual_date={"&lt;/SPAN&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;&amp;lt;=$(=monthend(=Max((common date)))"}&amp;gt;}distinct customer).&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 20 Dec 2013 11:42:04 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Set-analysis-issue/m-p/514233#M192097</guid>
      <dc:creator>israrkhan</dc:creator>
      <dc:date>2013-12-20T11:42:04Z</dc:date>
    </item>
    <item>
      <title>Re: Set analysis issue.</title>
      <link>https://community.qlik.com/t5/QlikView/Set-analysis-issue/m-p/514234#M192098</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Actually, problem is ,&amp;nbsp; common calendar and Fact table are not linked and I want data monthly , i.e. based on Common Month,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;By using commondate in set analysis, due to $ expansion, I use to get the minimum value of common date every time , but not according to the month of dimension,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Example&amp;gt;&amp;gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Min (commondate) is always clculated as 1-Jan-2012 in my case.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;but as month is in dimension,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I should get as&lt;/P&gt;&lt;P&gt;Jan&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 1-Jan-2012&lt;/P&gt;&lt;P&gt;Feb&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 1-Feb-2012&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;.&lt;/P&gt;&lt;P&gt;.&lt;/P&gt;&lt;P&gt;.&lt;/P&gt;&lt;P&gt;.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;regards&lt;/P&gt;&lt;P&gt;Nitin&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 20 Dec 2013 12:02:36 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Set-analysis-issue/m-p/514234#M192098</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2013-12-20T12:02:36Z</dc:date>
    </item>
    <item>
      <title>Re: Set analysis issue.</title>
      <link>https://community.qlik.com/t5/QlikView/Set-analysis-issue/m-p/514235#M192099</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi nitin,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Check the date format correctly.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 20 Dec 2013 12:24:42 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Set-analysis-issue/m-p/514235#M192099</guid>
      <dc:creator>senpradip007</dc:creator>
      <dc:date>2013-12-20T12:24:42Z</dc:date>
    </item>
    <item>
      <title>Re: Set analysis issue.</title>
      <link>https://community.qlik.com/t5/QlikView/Set-analysis-issue/m-p/514236#M192100</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Nitin,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Did you try &lt;STRONG&gt;InMonth()&lt;/STRONG&gt; function?&amp;nbsp; It may be better in your case.&amp;nbsp; It may look like this:&lt;BR /&gt;count(if(InMonth(actual_date, common_date,0),customer))&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;BR /&gt;Michael&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 20 Dec 2013 16:07:08 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Set-analysis-issue/m-p/514236#M192100</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2013-12-20T16:07:08Z</dc:date>
    </item>
    <item>
      <title>Re: Set analysis issue.</title>
      <link>https://community.qlik.com/t5/QlikView/Set-analysis-issue/m-p/514237#M192101</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;check whether the format in both actual_date and common date is same or not. If they are same,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;try the following expression,&lt;/P&gt;&lt;P&gt;count({$&amp;lt;actual_date={"&amp;gt;=$(=Date(monthstart(DATE#(min(common date), 'D-MMM-YYYY')), 'D-MMM-YYYY')) &amp;lt;$(=Date(monthend(DATE#(min(common date), 'D-MMM-YYYY')), 'D-MMM-YYYY'))"}&amp;gt;}distinct customer)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Because, sometimes if the left hand and right hand side of the expression doesn't show the same date format, the set analysis doesn't work at all and just show the count(distinct customer).&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 20 Dec 2013 16:24:52 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Set-analysis-issue/m-p/514237#M192101</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2013-12-20T16:24:52Z</dc:date>
    </item>
  </channel>
</rss>

