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
Syndicate_Admin
Administrator
Administrator

Count duplicates and power according to date range

Hello everyone, I am new to pbi and I have a doubt that I have not been able to solve for days. I have a table as follows:

nombre_ID | SN | date

S-YB90 001101

J-DS88 10101

S-YB90 001101

S-YB90 102133

and I have to count how many times it repeats nombre_ID = S-YB90 but if the SN is different, so in this example they are 2 times

With the following I have been able to tell it:

CALCULATE(COUNT(IMEI_Duplicados[SN]),ALLEXCEPT(IMEI_Duplicados,IMEI_Duplicados[nombre_ID]))
But the problem with this formula is that if I apply a slicer filter for example by date, it still throws me the duplicate total of the table and not the date range I select.
Do you have any suggestions?
4 REPLIES 4
Syndicate_Admin
Administrator
Administrator

Good morning!
@jav1985
consultation... Were you able to segment the date and have it taken for you?

Syndicate_Admin
Administrator
Administrator

Hi, thank you for your time in responding, but I still have problems.

Both cases that point to me I can not make my table show the way I want.

It turns out that when changing the filter by date, it is always showing me the values of the total number of times that RegistrationNumber is repeated as long as it has a different S/N.

in the following table I manage to do something, just show the number of times RegistrationNumber is repeated as long as it has a different S/N, by applying the filter in a date range. But now, I want it to be displayed when the totals are greater than 1. if you see in the last column "RegistrationNumber count" they give me the totals but when I put it to be greater than 1 I do not get anything, I understand why to display the result in each S / N equal to 1 ...

2023_03_10_13_46_30_Estado_CAS_Spence_Power_BI_Desktop.png

So what I want to achieve now is to be able to remove the values that are in "RegistrationNumber Count" < 2

2023_03_10_14_02_29_Estado_CAS_Spence_Power_BI_Desktop.png

Ashish_Mathur
Super User
Super User

Hi,

To your Table visual, drag Nombre_ID and this measure

Measure = distinctcount(Data[SN])

Hope this helps.


Regards,
Ashish Mathur
http://www.ashishmathur.com
https://www.linkedin.com/in/excelenthusiasts/
amitchandak
Super User
Super User

@Syndicate_Admin , Try like

CALCULATE(COUNT(IMEI_Duplicados[SN]),filter(allselected(IMEI_Duplicados) ,IMEI_Duplicados[nombre_ID] = max(IMEI_Duplicados[nombre_ID])))

Helpful resources

Announcements
Europe Fabric Conference

Europe’s largest Microsoft Fabric Community Conference

Join the community in Stockholm for expert Microsoft Fabric learning including a very exciting keynote from Arun Ulag, Corporate Vice President, Azure Data.

Power BI Carousel June 2024

Power BI Monthly Update - June 2024

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

RTI Forums Carousel3

New forum boards available in Real-Time Intelligence.

Ask questions in Eventhouse and KQL, Eventstream, and Reflex.