<?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: Flag Customer IDs based on count and year in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/Flag-Customer-IDs-based-on-count-and-year/m-p/15#M792816</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;&lt;A href="https://community.qlik.com/qlik-users/218859"&gt;loveisfail&lt;/A&gt; then how to flag the IDs by year?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Fri, 12 Jan 2018 17:13:04 GMT</pubDate>
    <dc:creator>karan_kn</dc:creator>
    <dc:date>2018-01-12T17:13:04Z</dc:date>
    <item>
      <title>Flag Customer IDs based on count and year</title>
      <link>https://community.qlik.com/t5/QlikView/Flag-Customer-IDs-based-on-count-and-year/m-p/12#M792813</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;The question will be little tricky:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Define a field based on a ID, when we select the current month from Sales_Date &lt;STRONG&gt;(ex: Nov 2017)&lt;/STRONG&gt;:&lt;/P&gt;&lt;P&gt;- New IDs of current month = &lt;STRONG&gt;NewITM,&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;- Duplicate IDs from historic data define by year&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;&amp;nbsp; &amp;gt;1 year OldITM &lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;&amp;nbsp; &amp;gt;2 year OldITM &lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;&amp;nbsp; &amp;gt;3 year OldITM&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;&lt;BR /&gt;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;IMG alt="imglo.PNG" class="jive-image image-1" src="https://community.qlik.com/legacyfs/online/189918_imglo.PNG" style="height: 466px; width: 620px;" /&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 25 Nov 2020 16:16:04 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Flag-Customer-IDs-based-on-count-and-year/m-p/12#M792813</guid>
      <dc:creator>karan_kn</dc:creator>
      <dc:date>2020-11-25T16:16:04Z</dc:date>
    </item>
    <item>
      <title>Re: Flag Customer IDs based on count and year</title>
      <link>https://community.qlik.com/t5/QlikView/Flag-Customer-IDs-based-on-count-and-year/m-p/13#M792814</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;May be?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;If(Count(CustID)&amp;gt;1, 'Duplicate', 'Regular')&lt;/STRONG&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 12 Jan 2018 15:13:26 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Flag-Customer-IDs-based-on-count-and-year/m-p/13#M792814</guid>
      <dc:creator>Anil_Babu_Samineni</dc:creator>
      <dc:date>2018-01-12T15:13:26Z</dc:date>
    </item>
    <item>
      <title>Re: Flag Customer IDs based on count and year</title>
      <link>https://community.qlik.com/t5/QlikView/Flag-Customer-IDs-based-on-count-and-year/m-p/14#M792815</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Karan, you can add a field with the first sale for each Id:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Join (SalesTable)&lt;/P&gt;&lt;P&gt;LOAD&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; CustID&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Min(Sales_Date) as FirstSale&lt;/P&gt;&lt;P&gt;Resident SalesTable&lt;/P&gt;&lt;P&gt;Group By &lt;SPAN style="font-size: 13.3333px;"&gt;CustID;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 13.3333px;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 13.3333px;"&gt;Having the first sale and the current sale of each Id in the same records makes easier to check the difference in years:&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 13.3333px;"&gt;Year(ThisSales)-Year(FirstSale) as YearsDiff&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 12 Jan 2018 15:52:40 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Flag-Customer-IDs-based-on-count-and-year/m-p/14#M792815</guid>
      <dc:creator>rubenmarin</dc:creator>
      <dc:date>2018-01-12T15:52:40Z</dc:date>
    </item>
    <item>
      <title>Re: Flag Customer IDs based on count and year</title>
      <link>https://community.qlik.com/t5/QlikView/Flag-Customer-IDs-based-on-count-and-year/m-p/15#M792816</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;&lt;A href="https://community.qlik.com/qlik-users/218859"&gt;loveisfail&lt;/A&gt; then how to flag the IDs by year?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 12 Jan 2018 17:13:04 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Flag-Customer-IDs-based-on-count-and-year/m-p/15#M792816</guid>
      <dc:creator>karan_kn</dc:creator>
      <dc:date>2018-01-12T17:13:04Z</dc:date>
    </item>
    <item>
      <title>Re: Flag Customer IDs based on count and year</title>
      <link>https://community.qlik.com/t5/QlikView/Flag-Customer-IDs-based-on-count-and-year/m-p/16#M792817</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thanks Ruben, but how to flag by year?&lt;/P&gt;&lt;P&gt;1 Year &lt;BR /&gt;2-3 Year&lt;BR /&gt;4-5 Year&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 12 Jan 2018 17:15:46 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Flag-Customer-IDs-based-on-count-and-year/m-p/16#M792817</guid>
      <dc:creator>karan_kn</dc:creator>
      <dc:date>2018-01-12T17:15:46Z</dc:date>
    </item>
    <item>
      <title>Re: Flag Customer IDs based on count and year</title>
      <link>https://community.qlik.com/t5/QlikView/Flag-Customer-IDs-based-on-count-and-year/m-p/17#M792818</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Like this, May be?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;If(Count(Year(Sales_Date))&amp;gt;1, 'NewITM', 'OldITM')&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;OR&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;If(Count(Year(Sales_Date))&amp;gt;0 and Count(Year(Sales_Date))&amp;lt;=1, '&amp;gt;1 year OLDITM',&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;If(Count(Year(Sales_Date))&amp;gt;1 and Count(Year(Sales_Date))&amp;lt;=2, '&amp;gt;2 year OLDITM'))&lt;/STRONG&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 13 Jan 2018 01:21:58 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Flag-Customer-IDs-based-on-count-and-year/m-p/17#M792818</guid>
      <dc:creator>Anil_Babu_Samineni</dc:creator>
      <dc:date>2018-01-13T01:21:58Z</dc:date>
    </item>
    <item>
      <title>Re: Flag Customer IDs based on count and year</title>
      <link>https://community.qlik.com/t5/QlikView/Flag-Customer-IDs-based-on-count-and-year/m-p/18#M792819</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;It's like the YearsDiff field, ie:&lt;/P&gt;&lt;P&gt;If(&lt;SPAN style="font-size: 13.3333px;"&gt;Year(ThisSales)-Year(FirstSale) &amp;gt;=4, '4+ Year',&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 13.3333px;"&gt;&amp;nbsp; If(&lt;SPAN style="font-size: 13.3333px;"&gt;Year(ThisSales)-Year(FirstSale) &amp;gt;=2, '2-3 Year', '1 Year'&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 13.3333px;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 13.3333px;"&gt;This only uses the year, not real dates differences, this is: between dec-17 and jan-18 there is 1 year; between jan-17 and dec-17 there are 0 years.&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 13 Jan 2018 10:51:18 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Flag-Customer-IDs-based-on-count-and-year/m-p/18#M792819</guid>
      <dc:creator>rubenmarin</dc:creator>
      <dc:date>2018-01-13T10:51:18Z</dc:date>
    </item>
  </channel>
</rss>

