Skip to main content
Woohoo! Qlik Community has won “Best in Class Community” in the 2024 Khoros Kudos awards!
Announcements
Nov. 20th, Qlik Insider - Lakehouses: Driving the Future of Data & AI - PICK A SESSION
cancel
Showing results for 
Search instead for 
Did you mean: 
sai_12
Contributor III
Contributor III

new user count based on year month

hello all,

I have a data problem similar to this, the client has multiple purchases on different dates,  i want to count the number of new users per year month

I only want to count the client on their first year month  of purchase  ->front end preferred

i have a table with all client information 

client purchase_Date
a 10/02/2022
a 10/02/2022
a 11/02/2023
a 11/02/2023
b 2/03/2022
b 3/03/2022
b 4/03/2022
c 5/12/2022

 

Expected output: something like this

Feb-22 1
Mar-22 1
Dec-22

1

 

Thank you in advance , front end preferred

Labels (2)
2 Replies
Ahidhar
Creator III
Creator III

have a look at this 

Ahidhar
Creator III
Creator III

Here is the code that I used 

 

Tab:
load * Inline
[
client,purchase_date
a,10/02/2022
a,10/02/2022
a,11/02/2023
a,11/02/2023
b,2/03/2022
b,3/03/2022
b,4/03/2022
c,5/12/2022
];


tab:
load
client,
min(purchase_date) as minvalue,
monthname(min(purchase_date)) as month,
1 as Flag
resident Tab
group by client;