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

Find everything you need to get certified on Fabric—skills challenges, live sessions, exam prep, role guidance, and more. Get started

Reply
Mohammadwazeri
Helper II
Helper II

If Item Is Available in More Than One Location Count It Once

Hi Everyone,

 

Would you please help me figure out this calculation?

I have more than one location and one Item may be available in more than one location.

 

1. I want to count the unique Item No. 

2. If one item is available in more than one location then count it one time.

3. Available Unique Count / Item No. Unique Count

 

Mohammadwazeri_0-1709241849596.png

 

Thank you!

Mohammad

4 REPLIES 4
selimovd
Super User
Super User

Hey @Mohammadwazeri ,

 

what did you try so far and where are you stuck?

 

Best regards

Denis

Hi @selimovd,

 

I did count the unique item no, but I couldn't figure out how to count if item is available in more than one location count it once.

 

Thanks,

Mohammad

Hey @Mohammadwazeri ,

 

here you go:

Unique Item No = DISTINCTCOUNT( myTable[Item No] )

 

I don't understand what you mean with "Available Unique Count".

Can you explain that?

 

If you need any help please let me know.
If I answered your question I would be happy if you could mark my post as a solution ✔️ and give it a thumbs up 👍

Best regards
Denis

Blog: WhatTheFact.bi
Follow me: twitter.com/DenSelimovic

Thank you, @selimovd  for your reply.

"Available", let's think of an auto part business that has a store in every city or state in the USA. 

Every store uses the same item # (ex: 12345) for the one part (winshield whipper).  This item exist only in three store, instead of counting this three times I want to count it only one time regardless of how many items available. If it's available in one store or in ten store just count it one time.

 

Best Regards,

Mohammad 

Helpful resources

Announcements
July 2024 Power BI Update

Power BI Monthly Update - July 2024

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

PBI_Carousel_NL_June

Fabric Community Update - June 2024

Get the latest Fabric updates from Build 2024, key Skills Challenge voucher deadlines, top blogs, forum posts, and product ideas.

Top Solution Authors