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

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more

Reply
ADSL
Post Prodigy
Post Prodigy

Total Distinct count is not matching with export data after mapping.

Dear Team Member,

 

I have an issue of Total Distint Count showing that it's not matching when mapping with export data. I had applied 02 measures as the following below.

1. Firstly, Dist_Count Active Store = DISTINCTCOUNT('Actual Sales'[Customer Code])

2. And then No. Active Customer = CALCULATE([Dist_Count Active Store],'Actual Sales'[BillingType]="ZF2",'Actual Sales'[Price Type]="SALE")

Total showing in table chart is 1207 but export data and count is 1217.

2022-08-30_21-08-32.jpg

Please kindly assist to check the screenshot, measure and advise.

4 REPLIES 4
ADSL
Post Prodigy
Post Prodigy

Dear @amitchandak

Thank you for your helpful feedback!

After trying your measure, I am getting issue as the screenshot. Please kindly check it.

2022-08-31_23-18-37.jpg

=> Just inform when I combine the sales rep code column with customer code and follow my existing measure then It's working now as per expectation.

Jihwan_Kim
Super User
Super User

Hi,

I am not sure how your dataset looks like, but please try to write the below measure and replace the current one with the below, and please check whether it suits your requirement.

 

New measure: =
SUMX ( VALUES ( 'TableName'[Sales Rep Code] ), [No. Active Customer] )

 


If this post helps, then please consider accepting it as the solution to help other members find it faster, and give a big thumbs up.


Click here to visit my LinkedIn page

Click here to schedule a short Teams meeting to discuss your question.

Dear @Jihwan_Kim , 

Thank you for your helpful feedback!

When trying your measure then getting error as the screenshot. Please kindly check it.

2022-08-31_23-27-52.jpg

=> I would like to inform that it's fixed after I am trying to combine sales rep & customer code column together and follow the exiting measure with this new column. Thanks a lot

amitchandak
Super User
Super User

@ADSL , Power bi recalculate grand total, means distinct count is calculated at total level and not a sum of rows

 

If you want to make it sum, try like

 

Sumx(values('Actual Sales'[Sales Rep code]),CALCULATE([Dist_Count Active Store],'Actual Sales'[BillingType]="ZF2",'Actual Sales'[Price Type]="SALE")  )

Share with Power BI Enthusiasts: Full Power BI Video (20 Hours) YouTube
Microsoft Fabric Series 60+ Videos YouTube
Microsoft Fabric Hindi End to End YouTube

Helpful resources

Announcements
Power BI DataViz World Championships

Power BI Dataviz World Championships

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now!

December 2025 Power BI Update Carousel

Power BI Monthly Update - December 2025

Check out the December 2025 Power BI Holiday Recap!

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.