How to count just a first sale by a client in tableau

172 Views Asked by At

I have a spreadsheet with clients first purchase I want to see how many new clients a month we are getting. However some of the clients we sell too could have the same name in a different zip code for example miami clinic could be in both florida and ohio so I want them counted individually. I also want to see the total new clinics per month. but if a clinic purchases in january and again in march i only want that january purchase counted

1

There are 1 best solutions below

0
On

Let us assume your sample data be like

enter image description here

Now create a calculated field first purchase date as

{Fixed [Clinic Name], [Zipcode]: min([Sale Date])}

This field will give each clinic its first purchase date only. Check it

enter image description here

Now to create a filter for first purchase date create a calculated field say first purchase filter as

[first purchase date] = [Sale Date]

Adding TRUE value filter (and don't forget to add the filter to context by right clicking it) will give sale amount in first purchases

enter image description here

OR use this filter for differentiation also

enter image description here

For any further query please share your actual data structure with a few rows and desired output in respect of those sample rows.