<?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: Expression Comparision in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/Expression-Comparision/m-p/268401#M1191503</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;&lt;SPAN style="font-family: trebuchet ms,geneva;"&gt;Hi Bikash,&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: trebuchet ms,geneva;"&gt;Reading this statement from your question...&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #ff9900;"&gt;&lt;EM style="font-family: trebuchet ms,geneva;"&gt;I need to count all those items those were in Pending stage in that particular month, has now converted to Design In or Design Win stage as of now.&lt;/EM&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: trebuchet ms,geneva;"&gt;I think you should be using Indirect Analysis within Set Analysis. I had similar requirement in the past and I got working with indirect Analysis. Below is the explanation, just in case you might need...&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: trebuchet ms,geneva;"&gt;The functions p() and e() can be used to select the set of possible or excluded values within a field.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG style=": ; font-family: trebuchet ms,geneva; text-decoration: underline;"&gt;Example:&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #000080;"&gt;&lt;STRONG style="font-family: trebuchet ms,geneva;"&gt;sum({$&amp;lt;CompanyName = p({$&amp;lt;CategoryName={'Baby Clothes'}&amp;gt;}&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #000080;"&gt;&lt;STRONG style="font-family: trebuchet ms,geneva;"&gt;CompanyName) - p({$&amp;lt;CategoryName={'SportsWear'}&amp;gt;}&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #000080;"&gt;&lt;STRONG style="font-family: trebuchet ms,geneva;"&gt;CompanyName)&amp;gt;} Sales)&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: trebuchet ms,geneva;"&gt;Sales for Customers who purchased Baby Clothes but not Sportswear.The first set p({}) returns CompanyName that purchased Baby Clothes.The second set p({}) returns CompanyName that&amp;nbsp; Purchased SportsWear.The Unary Operator "-" between the two gives a list of Customers (CompanyName)that belong to the first but not the other set.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: trebuchet ms,geneva;"&gt;However, if you can upload the QV document with some sample data. Then it will make it much simple to answer your question.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG style="font-family: trebuchet ms,geneva;"&gt;Cheers - DV&lt;/STRONG&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Sat, 09 Jul 2011 10:16:38 GMT</pubDate>
    <dc:creator>IAMDV</dc:creator>
    <dc:date>2011-07-09T10:16:38Z</dc:date>
    <item>
      <title>Expression Comparision</title>
      <link>https://community.qlik.com/t5/QlikView/Expression-Comparision/m-p/268399#M1191500</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi All,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have this two expression in set analysis and I want to find those items for which&lt;/P&gt;&lt;P&gt;these two conditions matches.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Expression A. &lt;/P&gt;&lt;P&gt;count({$&amp;lt;FACT_TYPE={"Current"},LINE_ITEM_STATUS={'Design In', 'Design Win'},FLAG_HEALTH_REPORT={'1'}&amp;gt;}OppID)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Expression B.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;count({$&amp;lt;FACT_TYPE={"Baseline"},LINE_ITEM_STATUS={'Pending'},DATE_SK={$(vBaselineDayKey)},FLAG_HEALTH_REPORT={1}&amp;gt;}OppID )&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Expression A finds all the items that are in Design In or Design Win stage based on the current day data.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Expression B finds all the items that were in pending stage in the selected month.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I need to count all those items those were in Pending stage in that particular month, has now converted to Design In or Design Win stage as of now.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;We are looking into two different snapshots of data. Any thing older than this week is saved and termed as FACT_TYPE= 'Baseline' and all data from this week is termed as FACT_TYPE='Current'.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Hope our Qlikview experts could help me please,&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;Bikash&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 08 Jul 2011 18:19:01 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Expression-Comparision/m-p/268399#M1191500</guid>
      <dc:creator />
      <dc:date>2011-07-08T18:19:01Z</dc:date>
    </item>
    <item>
      <title>Re: Expression Comparision</title>
      <link>https://community.qlik.com/t5/QlikView/Expression-Comparision/m-p/268400#M1191502</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi bikashdebnath,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I think you want the intersection of the two sets with regard to OppID.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Maybe something like:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;count(distinct {&amp;lt; OppID = p({set1}) * p({set2}) &amp;gt;} OppID)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;i.e.&lt;/P&gt;&lt;P&gt; count(distinct {&amp;lt; OppID = p({$&amp;lt;FACT_TYPE={"Current"},LINE_ITEM_STATUS={'Design In', 'Design Win'},FLAG_HEALTH_REPORT={'1'}&amp;gt;})*&lt;/P&gt;&lt;P&gt;p({$&amp;lt;FACT_TYPE={"Baseline"},LINE_ITEM_STATUS={'Pending'},DATE_SK={$(vBaselineDayKey)},FLAG_HEALTH_REPORT={1}&amp;gt;}) OppID)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;which should set the intersection of the possible selections of your two sets for field OppID and count it.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;(Haven't tried it in editor so maybe I missed a bracket).&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Stefan&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 09 Jul 2011 00:05:09 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Expression-Comparision/m-p/268400#M1191502</guid>
      <dc:creator>swuehl</dc:creator>
      <dc:date>2011-07-09T00:05:09Z</dc:date>
    </item>
    <item>
      <title>Re: Expression Comparision</title>
      <link>https://community.qlik.com/t5/QlikView/Expression-Comparision/m-p/268401#M1191503</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;&lt;SPAN style="font-family: trebuchet ms,geneva;"&gt;Hi Bikash,&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: trebuchet ms,geneva;"&gt;Reading this statement from your question...&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #ff9900;"&gt;&lt;EM style="font-family: trebuchet ms,geneva;"&gt;I need to count all those items those were in Pending stage in that particular month, has now converted to Design In or Design Win stage as of now.&lt;/EM&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: trebuchet ms,geneva;"&gt;I think you should be using Indirect Analysis within Set Analysis. I had similar requirement in the past and I got working with indirect Analysis. Below is the explanation, just in case you might need...&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: trebuchet ms,geneva;"&gt;The functions p() and e() can be used to select the set of possible or excluded values within a field.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG style=": ; font-family: trebuchet ms,geneva; text-decoration: underline;"&gt;Example:&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #000080;"&gt;&lt;STRONG style="font-family: trebuchet ms,geneva;"&gt;sum({$&amp;lt;CompanyName = p({$&amp;lt;CategoryName={'Baby Clothes'}&amp;gt;}&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #000080;"&gt;&lt;STRONG style="font-family: trebuchet ms,geneva;"&gt;CompanyName) - p({$&amp;lt;CategoryName={'SportsWear'}&amp;gt;}&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #000080;"&gt;&lt;STRONG style="font-family: trebuchet ms,geneva;"&gt;CompanyName)&amp;gt;} Sales)&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: trebuchet ms,geneva;"&gt;Sales for Customers who purchased Baby Clothes but not Sportswear.The first set p({}) returns CompanyName that purchased Baby Clothes.The second set p({}) returns CompanyName that&amp;nbsp; Purchased SportsWear.The Unary Operator "-" between the two gives a list of Customers (CompanyName)that belong to the first but not the other set.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: trebuchet ms,geneva;"&gt;However, if you can upload the QV document with some sample data. Then it will make it much simple to answer your question.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG style="font-family: trebuchet ms,geneva;"&gt;Cheers - DV&lt;/STRONG&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 09 Jul 2011 10:16:38 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Expression-Comparision/m-p/268401#M1191503</guid>
      <dc:creator>IAMDV</dc:creator>
      <dc:date>2011-07-09T10:16:38Z</dc:date>
    </item>
  </channel>
</rss>

