<?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: Finding exiting and new Clients in App Development</title>
    <link>https://community.qlik.com/t5/App-Development/Finding-exiting-and-new-Clients/m-p/2020009#M84232</link>
    <description>&lt;P&gt;Hello,&lt;/P&gt;
&lt;P&gt;You can easily achieve this with selections&amp;nbsp;drag&amp;amp;drop a filter pane to your sheet and select 'New Customer' or 'Exit Customer'&lt;/P&gt;</description>
    <pubDate>Tue, 27 Dec 2022 09:44:20 GMT</pubDate>
    <dc:creator>BTIZAG_OA</dc:creator>
    <dc:date>2022-12-27T09:44:20Z</dc:date>
    <item>
      <title>Finding exiting and new Clients</title>
      <link>https://community.qlik.com/t5/App-Development/Finding-exiting-and-new-Clients/m-p/2019989#M84226</link>
      <description>&lt;P&gt;I want to find a list of exit and fresh clients from&amp;nbsp;customer ID by comparing current and previous month.&lt;/P&gt;
&lt;P&gt;for example only a list of clients should appear&amp;nbsp; if customer ID appears for the first time in the current month.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;thank you&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 27 Dec 2022 07:25:00 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Finding-exiting-and-new-Clients/m-p/2019989#M84226</guid>
      <dc:creator>Syedtahaali</dc:creator>
      <dc:date>2022-12-27T07:25:00Z</dc:date>
    </item>
    <item>
      <title>Re: Finding exiting and new Clients</title>
      <link>https://community.qlik.com/t5/App-Development/Finding-exiting-and-new-Clients/m-p/2019990#M84227</link>
      <description>&lt;P&gt;&lt;a href="https://community.qlik.com/t5/user/viewprofilepage/user-id/212016"&gt;@Syedtahaali&lt;/a&gt;&amp;nbsp; Could you please post some sample data and also expected output?&lt;/P&gt;</description>
      <pubDate>Tue, 27 Dec 2022 07:26:49 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Finding-exiting-and-new-Clients/m-p/2019990#M84227</guid>
      <dc:creator>sidhiq91</dc:creator>
      <dc:date>2022-12-27T07:26:49Z</dc:date>
    </item>
    <item>
      <title>Re: Finding exiting and new Clients</title>
      <link>https://community.qlik.com/t5/App-Development/Finding-exiting-and-new-Clients/m-p/2019992#M84228</link>
      <description>&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Qlik forum.png" style="width: 469px;"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/96916i488FDC3C30ADE155/image-size/large?v=v2&amp;amp;px=999" role="button" title="Qlik forum.png" alt="Qlik forum.png" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;Yellow marked is a 'fresh client' in the current month&amp;nbsp; which is may and red marked 'exit client'.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 27 Dec 2022 07:47:17 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Finding-exiting-and-new-Clients/m-p/2019992#M84228</guid>
      <dc:creator>Syedtahaali</dc:creator>
      <dc:date>2022-12-27T07:47:17Z</dc:date>
    </item>
    <item>
      <title>Re: Finding exiting and new Clients</title>
      <link>https://community.qlik.com/t5/App-Development/Finding-exiting-and-new-Clients/m-p/2020005#M84230</link>
      <description>&lt;P&gt;Hello syedtahaali&lt;/P&gt;
&lt;P&gt;You can try this hope it helps&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;inline:
load * Inline
[
month,customerID,ClientName,TotalAmount
31.03.2022,1,JPMorgan,27
31.03.2022,2,GoldmanSachs,800
30.04.2022,1,JPMorgan,27
30.04.2022,2,GoldmanSachs,800
30.04.2022,3,MorganStanley,25600
31.05.2022,1,JPMorgan,27
31.05.2022,2,GoldmanSachs,800
31.05.2022,4,SPGlobal,258000
];

temp:
Load
max(month) as currentmonth Resident inline;

let vCurrentDate = date(peek('currentmonth',0,'temp'));

drop Table temp;

Trace CurrentDate: $(vCurrentDate);

table1:
Mapping load
customerID,
'Current Customer' as CustomerStatus
Resident inline
Where month &amp;lt; '$(vCurrentDate)';

table2:
Mapping load
customerID,
'Current Customer' as CustomerStatus
Resident inline
Where month = '$(vCurrentDate)';

data:
Load
month,
customerID,
ClientName,
TotalAmount,
ApplyMap('table1',customerID,'New Customer') as applymap
Resident inline
where month = '$(vCurrentDate)';

Concatenate(data)
Load
month,
customerID,
ClientName,
TotalAmount,
ApplyMap('table2',customerID,'Exit Customer') as applymap
Resident inline
where month &amp;lt; '$(vCurrentDate)';

drop table inline;
&lt;/LI-CODE&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Capture.PNG" style="width: 871px;"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/96918iDDC151C38D839491/image-size/large?v=v2&amp;amp;px=999" role="button" title="Capture.PNG" alt="Capture.PNG" /&gt;&lt;/span&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 27 Dec 2022 09:18:25 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Finding-exiting-and-new-Clients/m-p/2020005#M84230</guid>
      <dc:creator>BTIZAG_OA</dc:creator>
      <dc:date>2022-12-27T09:18:25Z</dc:date>
    </item>
    <item>
      <title>Re: Finding exiting and new Clients</title>
      <link>https://community.qlik.com/t5/App-Development/Finding-exiting-and-new-Clients/m-p/2020007#M84231</link>
      <description>&lt;P&gt;Thank you so much for your response, but the result I'm looking for is shown in the picture below&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Expected output.png" style="width: 344px;"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/96919i20D1AC27B40054A5/image-size/large?v=v2&amp;amp;px=999" role="button" title="Expected output.png" alt="Expected output.png" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;I want this table to appear on a new table chart, labeled as 'Fresh clients'&amp;nbsp;which was present is current month.&lt;/P&gt;
&lt;P&gt;also I want this table to appear on a new table chart, labeled as 'Exit clients' which was not present is current month.&lt;/P&gt;</description>
      <pubDate>Tue, 27 Dec 2022 09:31:02 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Finding-exiting-and-new-Clients/m-p/2020007#M84231</guid>
      <dc:creator>Syedtahaali</dc:creator>
      <dc:date>2022-12-27T09:31:02Z</dc:date>
    </item>
    <item>
      <title>Re: Finding exiting and new Clients</title>
      <link>https://community.qlik.com/t5/App-Development/Finding-exiting-and-new-Clients/m-p/2020009#M84232</link>
      <description>&lt;P&gt;Hello,&lt;/P&gt;
&lt;P&gt;You can easily achieve this with selections&amp;nbsp;drag&amp;amp;drop a filter pane to your sheet and select 'New Customer' or 'Exit Customer'&lt;/P&gt;</description>
      <pubDate>Tue, 27 Dec 2022 09:44:20 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Finding-exiting-and-new-Clients/m-p/2020009#M84232</guid>
      <dc:creator>BTIZAG_OA</dc:creator>
      <dc:date>2022-12-27T09:44:20Z</dc:date>
    </item>
    <item>
      <title>Re: Finding exiting and new Clients</title>
      <link>https://community.qlik.com/t5/App-Development/Finding-exiting-and-new-Clients/m-p/2020289#M84250</link>
      <description>&lt;P&gt;I have followed your query but was unable to get the required result&lt;/P&gt;
&lt;P&gt;kindly check If I have done it correctly or am I missing something.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;												data:
LOAD Distinct
  Months,
   UID,
    "Code",
"Standard Name",
    "Group",
    RR,
    BB,
    A_limit,
    B_Limit,
    [A+B]_Limit,
    A_OS,
    B_OS,
    [A+B]_OS
FROM [lib://Data inputs/my input.qvd]
(qvd);


temp:
Load
 max(Months) as currentmonth Resident data;

let vCurrentDate = date(peek('currentmonth',0,'temp'));

drop Table temp;

Trace CurrentDate: $(vCurrentDate);

table1:
Mapping load
UID,
'Current Customer' as CustomerStatus
Resident data
 Where Months &amp;lt; '$(vCurrentDate)';

table2:
Mapping load
UID,
'Current Customer' as CustomerStatus
Resident data
Where Months = '$(vCurrentDate)';


Consolidateddata:
LOAD
  Months,
   UID,
    "Code",
"Standard Name" ,
    "Group",
    RR,
    BB,
    A_limit,
    B_Limit,
    [A+B]_Limit,
    A_OS,
    B_OS,
    [A+B]_OS
ApplyMap('table1',UID,'New Customer') as applymap
Resident data
where Months = '$(vCurrentDate)';

Concatenate(Consolidateddata)
Load
   Months,
   UID,
    "Code",
"Standard Name" ,
    "Group",
    RR,
    BB,
    A_limit,
    B_Limit,
    [A+B]_Limit,
    A_OS,
    B_OS,
    [A+B]_OS 
ApplyMap('table2',UID,'Exit Customer') as applymap
Resident data
where Months &amp;lt; '$(vCurrentDate)';

drop table data;







&lt;/LI-CODE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 28 Dec 2022 12:23:33 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Finding-exiting-and-new-Clients/m-p/2020289#M84250</guid>
      <dc:creator>Syedtahaali</dc:creator>
      <dc:date>2022-12-28T12:23:33Z</dc:date>
    </item>
    <item>
      <title>Re: Finding exiting and new Clients</title>
      <link>https://community.qlik.com/t5/App-Development/Finding-exiting-and-new-Clients/m-p/2020296#M84251</link>
      <description>&lt;P&gt;Hello its hard to find out whats wrong from here, can you provide excel/QVD file or the script log that you ran.&lt;/P&gt;</description>
      <pubDate>Wed, 28 Dec 2022 12:42:07 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Finding-exiting-and-new-Clients/m-p/2020296#M84251</guid>
      <dc:creator>BTIZAG_OA</dc:creator>
      <dc:date>2022-12-28T12:42:07Z</dc:date>
    </item>
  </channel>
</rss>

