<?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: Caclulating Sales Close Rate with Set Analysis in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/Caclulating-Sales-Close-Rate-with-Set-Analysis/m-p/446569#M490552</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;Try like this&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 9pt; font-family: 'Courier New'; color: blue;"&gt;Count&lt;/SPAN&gt;&lt;SPAN style="font-size: 9pt; font-family: 'Courier New'; color: black;"&gt;(Distinct{$&amp;lt;&lt;/SPAN&gt;&lt;SPAN style="font-size: 9pt; font-family: 'Courier New'; color: maroon;"&gt;YearMonth&lt;/SPAN&gt;&lt;SPAN style="font-size: 9pt; font-family: 'Courier New'; color: black;"&gt;={&lt;/SPAN&gt;&lt;SPAN style="font-size: 9pt; font-family: 'Courier New'; color: maroon;"&gt;"$(=Max(Opportunity_Closed_Year_Month))"&lt;/SPAN&gt;&lt;SPAN style="font-size: 9pt; font-family: 'Courier New'; color: black;"&gt;},Opportunity_ClosedWon&lt;/SPAN&gt;&lt;SPAN style="font-size: 9pt; font-family: 'Courier New'; color: maroon;"&gt;e&lt;/SPAN&gt;&lt;SPAN style="font-size: 9pt; font-family: 'Courier New'; color: black;"&gt; = {&lt;/SPAN&gt;&lt;SPAN style="font-size: 9pt; font-family: 'Courier New'; color: maroon;"&gt;"true"&lt;/SPAN&gt;&lt;SPAN style="font-size: 9pt; font-family: 'Courier New'; color: black;"&gt;}&amp;gt;} Opportunity_Number)&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #000000; font-size: 12px; font-family: 'Courier New';"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Thu, 27 Sep 2012 22:44:36 GMT</pubDate>
    <dc:creator>MayilVahanan</dc:creator>
    <dc:date>2012-09-27T22:44:36Z</dc:date>
    <item>
      <title>Caclulating Sales Close Rate with Set Analysis</title>
      <link>https://community.qlik.com/t5/QlikView/Caclulating-Sales-Close-Rate-with-Set-Analysis/m-p/446564#M490547</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;&lt;SPAN style="font-size: 12.0pt;"&gt;Hey Qlik-Gurus,&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 12.0pt;"&gt;I'm in desparate need of some Set Analysis help. &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 12.0pt;"&gt;I’m trying to calculate our Closed Rate % of our opportunities each month and the definition is as follows:&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 12.0pt;"&gt;Numerator – Count of Opportunities Closed Won this month with any created date&amp;nbsp; (the easy part)&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 12.0pt;"&gt;Denominator – Count of Opps Created this month with any closed date (what I need help with)&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 12.0pt;"&gt;The tricky part is there being two time dimensions (Opp Closed Month and Opp Created Month).&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 12.0pt;"&gt;Here’s the current expression calculation:&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 9.0pt; font-family: 'Courier New'; color: black;"&gt;=&lt;/SPAN&gt;&lt;SPAN style="font-size: 9.0pt; font-family: 'Courier New'; color: blue;"&gt;COUNT&lt;/SPAN&gt;&lt;SPAN style="font-size: 9.0pt; font-family: 'Courier New'; color: black;"&gt;(&lt;/SPAN&gt;&lt;SPAN style="font-size: 9.0pt; font-family: 'Courier New'; color: blue;"&gt;DISTINCT&lt;/SPAN&gt; &lt;SPAN style="font-size: 9.0pt; font-family: 'Courier New'; color: blue;"&gt;if&lt;/SPAN&gt;&lt;SPAN style="font-size: 9.0pt; font-family: 'Courier New'; color: black;"&gt;(&lt;/SPAN&gt;&lt;SPAN style="font-size: 9.0pt; font-family: 'Courier New'; color: maroon;"&gt;Opp_Stage&lt;/SPAN&gt;&lt;SPAN style="font-size: 9.0pt; font-family: 'Courier New'; color: black;"&gt; = 'Closed Won' ,&lt;/SPAN&gt;&lt;SPAN style="font-size: 9.0pt; font-family: 'Courier New'; color: maroon;"&gt;OppNumber&lt;/SPAN&gt;&lt;SPAN style="font-size: 9.0pt; font-family: 'Courier New'; color: black;"&gt;))&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 9.0pt; font-family: 'Courier New'; color: black;"&gt;/&lt;/SPAN&gt;&lt;SPAN style="font-size: 9.0pt; font-family: 'Courier New'; color: blue;"&gt;COUNT&lt;/SPAN&gt;&lt;SPAN style="font-size: 9.0pt; font-family: 'Courier New'; color: black;"&gt;(&lt;/SPAN&gt;&lt;SPAN style="font-size: 9.0pt; font-family: 'Courier New'; color: blue;"&gt;DISTINCT&lt;/SPAN&gt; &lt;SPAN style="font-size: 9.0pt; font-family: 'Courier New'; color: blue;"&gt;if&lt;/SPAN&gt;&lt;SPAN style="font-size: 9.0pt; font-family: 'Courier New'; color: black;"&gt;(&lt;/SPAN&gt;&lt;SPAN style="font-size: 9.0pt; font-family: 'Courier New'; color: maroon;"&gt;Opp_IsClosed_Flag&lt;/SPAN&gt;&lt;SPAN style="font-size: 9.0pt; font-family: 'Courier New'; color: black;"&gt; = 'true' ,&lt;/SPAN&gt;&lt;SPAN style="font-size: 9.0pt; font-family: 'Courier New'; color: maroon;"&gt;OppNumber&lt;/SPAN&gt;&lt;SPAN style="font-size: 9.0pt; font-family: 'Courier New'; color: black;"&gt;)) &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 12.0pt;"&gt;And my dimension is the Opportunity Closed Year-Month – where I need to figure out how to incorporate the Opp Created Year Month dimension in the denominator. Putting a different a different set within an if statement adds another layer of complexity.&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 12pt;"&gt;Any help or advice here would be super appreciated!&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 12.0pt;"&gt;Thanks,&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 12.0pt;"&gt;Andy&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 26 Sep 2012 19:55:04 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Caclulating-Sales-Close-Rate-with-Set-Analysis/m-p/446564#M490547</guid>
      <dc:creator>andyquirin</dc:creator>
      <dc:date>2012-09-26T19:55:04Z</dc:date>
    </item>
    <item>
      <title>Re: Caclulating Sales Close Rate with Set Analysis</title>
      <link>https://community.qlik.com/t5/QlikView/Caclulating-Sales-Close-Rate-with-Set-Analysis/m-p/446565#M490548</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Andy,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I assume one issue is that your records are grouped by your Opp Closed Month, and you then miss records for current dimension Month = Opp Created Month, where Created Month &amp;lt;&amp;gt; Closed Month (assuming that closed month and created month are two fields in the same table).&lt;/P&gt;&lt;P&gt;You can work around this by using a common Date / Month field and distinguis between Closed and Created by a type field, transforming your source table from a cross table to a straight table, maybe like:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;EM&gt;INPUT:&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;&lt;EM&gt;&lt;STRONG&gt;CROSSTABLE (Type, Date) LOAD&lt;/STRONG&gt; * INLINE [&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;&lt;EM&gt;Opp, OppCreated, OppClosed&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;&lt;EM&gt;A, 01.09.2012, 01.09.2012&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;&lt;EM&gt;B, 01.09.2012, 01.10.2012&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;&lt;EM&gt;C, 01.08.2012, 01.10.2012&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;&lt;EM&gt;];&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Then you can use your Date field as dimension and change your expression to&lt;/P&gt;&lt;P&gt;&lt;EM&gt;=count({&amp;lt;Type = {'OppClosed'}&amp;gt;} Opp) / count({&amp;lt;Type = {'OppCreated'}&amp;gt;} Opp)&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;{you can also include your other fields like Stage and IsClosed into these set expressions}&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Hope this helps,&lt;/P&gt;&lt;P&gt;Stefan&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 27 Sep 2012 09:31:40 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Caclulating-Sales-Close-Rate-with-Set-Analysis/m-p/446565#M490548</guid>
      <dc:creator>swuehl</dc:creator>
      <dc:date>2012-09-27T09:31:40Z</dc:date>
    </item>
    <item>
      <title>Re: Caclulating Sales Close Rate with Set Analysis</title>
      <link>https://community.qlik.com/t5/QlikView/Caclulating-Sales-Close-Rate-with-Set-Analysis/m-p/446566#M490549</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Stefan,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks for the help - I think we're in the right direction. We've created a date island as the new common date based on your advice. I tried an iteration of the cross table but couldn't get it to work. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Here's the updated code, but still not working:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 9.0pt; font-family: 'Courier New'; color: blue;"&gt;Numerator - Count&lt;/SPAN&gt;&lt;SPAN style="font-size: 9.0pt; font-family: 'Courier New'; color: black;"&gt;(Distinct{$&amp;lt;&lt;/SPAN&gt;&lt;SPAN style="font-size: 9.0pt; font-family: 'Courier New'; color: maroon;"&gt;YearMonth&lt;/SPAN&gt;&lt;SPAN style="font-size: 9.0pt; font-family: 'Courier New'; color: black;"&gt;={&lt;/SPAN&gt;&lt;SPAN style="font-size: 9.0pt; font-family: 'Courier New'; color: maroon;"&gt;"Opportunity_Closed_Year_Month"&lt;/SPAN&gt;&lt;SPAN style="font-size: 9.0pt; font-family: 'Courier New'; color: black;"&gt;},Opportunity_ClosedWon&lt;/SPAN&gt;&lt;SPAN style="font-size: 9.0pt; font-family: 'Courier New'; color: maroon;"&gt;e&lt;/SPAN&gt;&lt;SPAN style="font-size: 9.0pt; font-family: 'Courier New'; color: black;"&gt; = {&lt;/SPAN&gt;&lt;SPAN style="font-size: 9.0pt; font-family: 'Courier New'; color: maroon;"&gt;"true"&lt;/SPAN&gt;&lt;SPAN style="font-size: 9.0pt; font-family: 'Courier New'; color: black;"&gt;}&amp;gt;} Opportunity_Number)&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 9.0pt; font-family: 'Courier New'; color: black;"&gt;Denominator - COUNT(DISTINCT {$&amp;lt;&lt;/SPAN&gt;&lt;SPAN style="font-size: 9.0pt; font-family: 'Courier New'; color: maroon;"&gt; YearMonth&lt;/SPAN&gt;&lt;SPAN style="font-size: 9.0pt; font-family: 'Courier New'; color: black;"&gt;={&lt;/SPAN&gt;&lt;SPAN style="font-size: 9.0pt; font-family: 'Courier New'; color: maroon;"&gt;"Opportunity_Created_Year_Month"&lt;/SPAN&gt;&lt;SPAN style="font-size: 9.0pt; font-family: 'Courier New'; color: black;"&gt;},Opportunity_Closed = {&lt;/SPAN&gt;&lt;SPAN style="font-size: 9.0pt; font-family: 'Courier New'; color: maroon;"&gt;"true"&lt;/SPAN&gt;&lt;SPAN style="font-size: 9.0pt; font-family: 'Courier New'; color: black;"&gt;}&amp;gt;} Opportunity_Number)&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 9.0pt; font-family: 'Courier New'; color: black;"&gt;Andy&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 27 Sep 2012 21:58:54 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Caclulating-Sales-Close-Rate-with-Set-Analysis/m-p/446566#M490549</guid>
      <dc:creator>andyquirin</dc:creator>
      <dc:date>2012-09-27T21:58:54Z</dc:date>
    </item>
    <item>
      <title>Re: Caclulating Sales Close Rate with Set Analysis</title>
      <link>https://community.qlik.com/t5/QlikView/Caclulating-Sales-Close-Rate-with-Set-Analysis/m-p/446567#M490550</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Andy, &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;could you post the relevant script code, too? Or maybe a small sample app?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 27 Sep 2012 22:06:43 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Caclulating-Sales-Close-Rate-with-Set-Analysis/m-p/446567#M490550</guid>
      <dc:creator>swuehl</dc:creator>
      <dc:date>2012-09-27T22:06:43Z</dc:date>
    </item>
    <item>
      <title>Re: Caclulating Sales Close Rate with Set Analysis</title>
      <link>https://community.qlik.com/t5/QlikView/Caclulating-Sales-Close-Rate-with-Set-Analysis/m-p/446568#M490551</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Sure thing - thanks for your help!&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Opp Table:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;SELECT &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; YEAR(a.[CREATEDDATE])&amp;nbsp;&amp;nbsp;&amp;nbsp; as [Opportunity_Created_Year]&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; ,MONTH(a.[CREATEDDATE])&amp;nbsp;&amp;nbsp;&amp;nbsp; as [Opportunity_Created_Month]&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; ,YEAR(a.[CLOSEDATE])&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; as [Opportunity_Closed_Year]&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; ,MONTH(a.[CLOSEDATE])&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; as [Opportunity_Closed_Month]&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; ,CAST(YEAR(a.[CREATEDDATE])&amp;nbsp;&amp;nbsp;&amp;nbsp; as varchar)&amp;nbsp;&amp;nbsp;&amp;nbsp; + '-' +&amp;nbsp; CAST(MONTH(a.[CREATEDDATE]) as varchar)&amp;nbsp;&amp;nbsp;&amp;nbsp; as [Opportunity_Created_Year_Month]&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; ,CAST(YEAR(a.[CLOSEDATE])&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; as varchar)&amp;nbsp;&amp;nbsp;&amp;nbsp; + '-' +&amp;nbsp; CAST(MONTH(a.[CLOSEDATE])&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; as varchar)&amp;nbsp;&amp;nbsp;&amp;nbsp; as [Opportunity_Closed_Year_Month]&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; ,CAST(YEAR(a.[SYSTEMMODSTAMP])&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; as varchar)&amp;nbsp;&amp;nbsp;&amp;nbsp; + '-' +&amp;nbsp; CAST(MONTH(a.[SYSTEMMODSTAMP])&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; as varchar)&amp;nbsp;&amp;nbsp;&amp;nbsp; as [Opportunity_Mod_Year_Month]&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; ,a.[SYSTEMMODSTAMP]&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; as [Opportunity_Mod_Date]&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; ,a.[CREATEDDATE]&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; as [Opportunity_Create_Date]&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; ,a.[CLOSEDATE]&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; as [Opportunity_Closed_Date]&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; ,a.[NAMEX]&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; as [Opportunity_Name]&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; ,a.[DESCRIPTION]&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; as [Opportunity_Description]&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; ,a.[STAGENAME]&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; as [Opportunity_Stage]&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; ,a.[ISCLOSED]&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; as [Opportunity_IsClosed_Flag]&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; ,a.[ISWON]&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; as [Opportunity_IsWon_Flag]&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; ,a.[OPPORTUNITY_ID]&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; as [Opportunity_Number]&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/P&gt;&lt;P&gt;&amp;nbsp; FROM [OPPORTUNITY] a &lt;/P&gt;&lt;P&gt;&amp;nbsp; &lt;/P&gt;&lt;P&gt;&amp;nbsp; WHERE &lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; a.[DELETE_FLAG] = 'N'&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; and a.[CREATEDDATE] &amp;gt; '2012-01-01'&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;------------------------------&lt;/P&gt;&lt;P&gt;Date Island:&lt;/P&gt;&lt;P&gt;LET varMinDate = NUM('1/1/2012'); &lt;/P&gt;&lt;P&gt;LET varMaxDate = NUM(today(0));&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;TempCalendar:&lt;/P&gt;&lt;P&gt;LOAD&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; $(varMinDate)+Iterno()-1 AS Num,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; Date($(varMinDate)+Iterno()-1) AS TempDate&lt;/P&gt;&lt;P&gt;AUTOGENERATE 1 WHILE $(varMinDate)+Iterno()-1 &amp;lt;= $(varMaxDate);&lt;/P&gt;&lt;P&gt;Calendar:&lt;/P&gt;&lt;P&gt;load &lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; TempDate AS RecordDate,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; date(monthstart(TempDate), 'YYYY-M') AS YearMonth&lt;/P&gt;&lt;P&gt;MonthEnd(TempDate)))) as LastDayOfMonth&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/P&gt;&lt;P&gt;resident TempCalendar&amp;nbsp; order by TempDate Asc;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Drop table TempCalendar;&lt;/P&gt;&lt;P&gt;--------------------------------&lt;/P&gt;&lt;P&gt;Dimension:&lt;/P&gt;&lt;P&gt;=If(Opportunity_Closed_Year_Month = YearMonth &lt;/P&gt;&lt;P&gt;or Opportunity_Created_Year_Month = YearMonth&lt;/P&gt;&lt;P&gt;,YearMonth) &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Expression:&lt;/P&gt;&lt;P&gt;=Count(Distinct{$&amp;lt;YearMonth={"Opportunity_Closed_Year_Month"},Opportunity_IsWon_Flag = {"true"}&amp;gt;} Opportunity_Number)&lt;/P&gt;&lt;P&gt;/ COUNT(DISTINCT {$&amp;lt; YearMonth={"Opportunity_Created_Year_Month"},Opportunity_IsClosed_Flag = {"true"}&amp;gt;} Opportunity_Number)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;------------------------------&lt;/P&gt;&lt;P&gt;Goal:&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 12.0pt;"&gt;calculate our Closed Rate % of our opportunities each month and the definition is as follows:&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt; &lt;SPAN style="font-size: 12.0pt;"&gt;Numerator – Count of Opportunities Closed Won this month with any created date &lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 12.0pt;"&gt;Denominator – Count of Opps Created this month with any closed date &lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 27 Sep 2012 22:26:12 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Caclulating-Sales-Close-Rate-with-Set-Analysis/m-p/446568#M490551</guid>
      <dc:creator>andyquirin</dc:creator>
      <dc:date>2012-09-27T22:26:12Z</dc:date>
    </item>
    <item>
      <title>Re: Caclulating Sales Close Rate with Set Analysis</title>
      <link>https://community.qlik.com/t5/QlikView/Caclulating-Sales-Close-Rate-with-Set-Analysis/m-p/446569#M490552</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;Try like this&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 9pt; font-family: 'Courier New'; color: blue;"&gt;Count&lt;/SPAN&gt;&lt;SPAN style="font-size: 9pt; font-family: 'Courier New'; color: black;"&gt;(Distinct{$&amp;lt;&lt;/SPAN&gt;&lt;SPAN style="font-size: 9pt; font-family: 'Courier New'; color: maroon;"&gt;YearMonth&lt;/SPAN&gt;&lt;SPAN style="font-size: 9pt; font-family: 'Courier New'; color: black;"&gt;={&lt;/SPAN&gt;&lt;SPAN style="font-size: 9pt; font-family: 'Courier New'; color: maroon;"&gt;"$(=Max(Opportunity_Closed_Year_Month))"&lt;/SPAN&gt;&lt;SPAN style="font-size: 9pt; font-family: 'Courier New'; color: black;"&gt;},Opportunity_ClosedWon&lt;/SPAN&gt;&lt;SPAN style="font-size: 9pt; font-family: 'Courier New'; color: maroon;"&gt;e&lt;/SPAN&gt;&lt;SPAN style="font-size: 9pt; font-family: 'Courier New'; color: black;"&gt; = {&lt;/SPAN&gt;&lt;SPAN style="font-size: 9pt; font-family: 'Courier New'; color: maroon;"&gt;"true"&lt;/SPAN&gt;&lt;SPAN style="font-size: 9pt; font-family: 'Courier New'; color: black;"&gt;}&amp;gt;} Opportunity_Number)&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #000000; font-size: 12px; font-family: 'Courier New';"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 27 Sep 2012 22:44:36 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Caclulating-Sales-Close-Rate-with-Set-Analysis/m-p/446569#M490552</guid>
      <dc:creator>MayilVahanan</dc:creator>
      <dc:date>2012-09-27T22:44:36Z</dc:date>
    </item>
    <item>
      <title>Re: Caclulating Sales Close Rate with Set Analysis</title>
      <link>https://community.qlik.com/t5/QlikView/Caclulating-Sales-Close-Rate-with-Set-Analysis/m-p/446570#M490553</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Andy,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;that's not the same approach I suggested, my approach does not create a data island. One can probably work out a solution using a data island, but I think this is not needed here (and should be avoided, since it adds complexity and is not as performant, IMHO).&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Please check attached (mostly the same as posted above, tried to adapt a little closer to your table layout).&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>Fri, 28 Sep 2012 15:29:00 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Caclulating-Sales-Close-Rate-with-Set-Analysis/m-p/446570#M490553</guid>
      <dc:creator>swuehl</dc:creator>
      <dc:date>2012-09-28T15:29:00Z</dc:date>
    </item>
    <item>
      <title>Re: Caclulating Sales Close Rate with Set Analysis</title>
      <link>https://community.qlik.com/t5/QlikView/Caclulating-Sales-Close-Rate-with-Set-Analysis/m-p/446571#M490554</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hey Stefan,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks for sending over the example.&lt;/P&gt;&lt;P&gt;On your Input table, how would I populate this portion without typing it in manually?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;01.09.2012, 01.09.2012, 10.10.2012, A, Aa, ??, true, true, 1 &lt;/P&gt;&lt;P&gt;01.09.2012, 01.10.2012, 10.10.2012, B, Bb, ??, false, false, 2&lt;/P&gt;&lt;P&gt;01.08.2012, 01.10.2012, 10.10.2012, C, Cc, ??, true, false, 3&lt;/P&gt;&lt;P&gt;01.09.2012, 01.09.2012, 10.10.2012, D, Dd, ??, false, false, 4 &lt;/P&gt;&lt;P&gt;01.10.2012, 01.10.2012, 10.10.2012, E, Ee, ??, true, true, 5&lt;/P&gt;&lt;P&gt;01.08.2012, 01.10.2012, 10.10.2012, F, Ff, ??, true, false, 6&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I've got around a million opportunities I need automatically inlcuded.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks for your help - I really appreciate it.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Andy&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 28 Sep 2012 15:37:51 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Caclulating-Sales-Close-Rate-with-Set-Analysis/m-p/446571#M490554</guid>
      <dc:creator>andyquirin</dc:creator>
      <dc:date>2012-09-28T15:37:51Z</dc:date>
    </item>
    <item>
      <title>Re: Caclulating Sales Close Rate with Set Analysis</title>
      <link>https://community.qlik.com/t5/QlikView/Caclulating-Sales-Close-Rate-with-Set-Analysis/m-p/446572#M490555</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;That's an INLINE LOAD:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;LOAD * &lt;/P&gt;&lt;P&gt;INLINE [&lt;/P&gt;&lt;P&gt;CREATEDDATE,CLOSEDATE,SYSTEMMODSTAMP,NAMEX,DESCRIPTION,STAGENAME,ISCLOSED,ISWON,OPPORTUNITY_ID&lt;/P&gt;&lt;P&gt;01.09.2012, 01.09.2012, 10.10.2012, A, Aa, ??, true, true, 1 &lt;/P&gt;&lt;P&gt;01.09.2012, 01.10.2012, 10.10.2012, B, Bb, ??, false, false, 2&lt;/P&gt;&lt;P&gt;01.08.2012, 01.10.2012, 10.10.2012, C, Cc, ??, true, false, 3&lt;/P&gt;&lt;P&gt;01.09.2012, 01.09.2012, 10.10.2012, D, Dd, ??, false, false, 4 &lt;/P&gt;&lt;P&gt;01.10.2012, 01.10.2012, 10.10.2012, E, Ee, ??, true, true, 5&lt;/P&gt;&lt;P&gt;01.08.2012, 01.10.2012, 10.10.2012, F, Ff, ??, true, false, 6&lt;/P&gt;&lt;P&gt;];&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I tried to use your source table field names, so to replace the INLINE Load with your data source, just use&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;SELECT *&lt;/P&gt;&lt;P&gt;FROM [OPPORTUNITY];&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If needed, adapt the field names in my sample code.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 28 Sep 2012 15:48:51 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Caclulating-Sales-Close-Rate-with-Set-Analysis/m-p/446572#M490555</guid>
      <dc:creator>swuehl</dc:creator>
      <dc:date>2012-09-28T15:48:51Z</dc:date>
    </item>
    <item>
      <title>Re: Caclulating Sales Close Rate with Set Analysis</title>
      <link>https://community.qlik.com/t5/QlikView/Caclulating-Sales-Close-Rate-with-Set-Analysis/m-p/446573#M490556</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hey Stefan,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I loaded my opportunities table and the Year_Month field are all populating null.&lt;/P&gt;&lt;P&gt;Any ideas?&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;Andy&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;IMG __jive_id="22683" class="jive-image-thumbnail jive-image" height="240" onclick="" alt="OppYearMonth.jpg" src="https://community.qlik.com/legacyfs/online/22683_OppYearMonth.jpg" width="650" /&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 28 Sep 2012 16:23:30 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Caclulating-Sales-Close-Rate-with-Set-Analysis/m-p/446573#M490556</guid>
      <dc:creator>andyquirin</dc:creator>
      <dc:date>2012-09-28T16:23:30Z</dc:date>
    </item>
    <item>
      <title>Re: Caclulating Sales Close Rate with Set Analysis</title>
      <link>https://community.qlik.com/t5/QlikView/Caclulating-Sales-Close-Rate-with-Set-Analysis/m-p/446574#M490557</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Please compare your script to the one I've attached above. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I don't create Opportunity_Closed_Year_Month / Opportunity_Created_Year_Month at all. These fields are replaced by Opp_Type and Year_Month in the CROSSTABLE Load.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 28 Sep 2012 16:29:22 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Caclulating-Sales-Close-Rate-with-Set-Analysis/m-p/446574#M490557</guid>
      <dc:creator>swuehl</dc:creator>
      <dc:date>2012-09-28T16:29:22Z</dc:date>
    </item>
  </channel>
</rss>

