Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
nulldemon
Frequent Visitor

Need Help Calculating repeat customers Percent monthly from Customer and sales

Team Leads have agents below them. Each agent books loads. We want to know which agent has repeat carrier business. As you can see When clicking on Dax in the month of April, he used carrier Bline 3 times. If they use the carrier 3 times or more, we count that as repeat carrier regardless of the customer. Dax in the month of May has 3 loads.

 

What we need help with to make is one table that gives the Percent of total loads booked / by repeat carriers.  For example Dax booked a total of 5 loads in April. 3 of them were repeat carriers. His percent would be 60% for April. In May his repeat would be 75% So we want Aa table that gives all agents there repeat carrier % as well as adding up the team leads

 

 

 

 

We want it to look like this

 

look like this.PNG

 

Here is a example PBIX 

 

 

Example of the sample 

https://drive.google.com/file/d/1sam1CVOy50QCT31zzRh1Uup4qYDpJwrl/view?usp=sharing

help.PNG

1 ACCEPTED SOLUTION

Change the repeat formula to

Repeat = 
var l1 =SUMMARIZE(Sheet1,Sheet1[Carrier],"G1",SUM(Sheet1[Loads]))
var _rep= CALCULATE(sumx(filter(l1,[G1]>1),[G1]))
return _rep

Appreciate your Kudos. In case, this is the solution you are looking for, mark it as the Solution. In case it does not help, please provide additional information and mark me with @
Thanks.

View solution in original post

3 REPLIES 3
amitchandak
Super User
Super User

I created formulas and added a visual on page 2. But the requirement of getting values above dimension seems to have limitation 

 

https://www.dropbox.com/s/8q0ki3p25ruxmse/test%281%29.pbix?dl=0\

 

Refer

https://community.powerbi.com/t5/Desktop/Matrix-Column-Headers-Measures-before-Dimension-SSAS/td-p/3...

 

Appreciate your Kudos. In case, this is the solution you are looking for, mark it as the Solution. In case it does not help, please provide additional information and mark me with @
Thanks.

I added it to our main dataset. Here is what we are getting. 

 

rrrr.PNG

So we look at brandon he had 86 loads. so the math should be 7/86 should be 0.08138 or 8.1%

 

it is showing 0.03.

 

So we are filtering out what agent has booked more than 3 loads with one carrier.  

 

 

Change the repeat formula to

Repeat = 
var l1 =SUMMARIZE(Sheet1,Sheet1[Carrier],"G1",SUM(Sheet1[Loads]))
var _rep= CALCULATE(sumx(filter(l1,[G1]>1),[G1]))
return _rep

Appreciate your Kudos. In case, this is the solution you are looking for, mark it as the Solution. In case it does not help, please provide additional information and mark me with @
Thanks.

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

Find out what's new and trending in the Fabric Community.