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

Prepping for a Fabric certification exam? Join us for a live prep session with exam experts to learn how to pass the exam. Register now.

Reply
Syndicate_Admin
Administrator
Administrator

Verify data from different columns to verify data from another

I need to count the TAG (Team TAG) that are correct, for that I have to count the blanks in the "Name Rule" column, the values in the "Team Number" column that contain letters and count from the "Repeated" column the values other than 1.

LoretoF_0-1722527117473.png

Please help you

1 ACCEPTED SOLUTION
Anonymous
Not applicable

Hello,@Ashish_Mathur ,@Daniel29195 ,thanks for your concern about this issue.

Your answer is excellent! And I would like to share some additional solutions below.
Hi,@Loreto-F .I am glad to help you.
You can refer to my test below
Here is my test data:

vjtianmsft_0-1723111226121.png

Since the filtering conditions you have given are not very specific, I have created a variety of scenarios to simulate the possible filtering conditions, and the results of the filtering of non-repeating counting

1. If you want to filter out the data range as follows, you can try the following measure2:

vjtianmsft_1-1723111256738.png

 

Measure 2 = 
VAR _table = SUMMARIZE('Table','Table'[Team TAG],'Table'[Team Number],'Table'[Repeated],'Table'[Name Rule],"ISZIMU",IFERROR(INT('Table'[Team Number]),0))
RETURN COUNTROWS(SUMMARIZE(FILTER(_table,'Table'[Repeated]<>1),'Table'[Team TAG]))

 

2. If you want to filter out the results as follows, you can try the following measure.

vjtianmsft_2-1723111309717.png

 

Measure = 
VAR _table = SUMMARIZE('Table','Table'[Team TAG],'Table'[Team Number],'Table'[Repeated],'Table'[Name Rule],"ISZIMU",IFERROR(INT('Table'[Team Number]),0))
RETURN COUNTROWS(SUMMARIZE(FILTER(_table,'Table'[Repeated]<>1&&([ISZIMU]=0||'Table'[Name Rule]=BLANK())),'Table'[Team TAG]))

 

3. If you only want to filter out records with 'Table' [Repeated] column <> 1, you can use measure3 below:

vjtianmsft_3-1723111360219.png

 

Measure 3 = 
VAR _table = SUMMARIZE('Table','Table'[Team TAG],'Table'[Team Number],'Table'[Repeated],'Table'[Name Rule],"ISZIMU",IFERROR(INT('Table'[Team Number]),0))
RETURN COUNTROWS(SUMMARIZE(FILTER(_table,'Table'[Repeated]=1&&('Table'[Team Number]<>BLANK()||[ISZIMU]<>0)),'Table'[Team TAG]))

 

If you can explain your filtering criteria in detail and explain the filtering relationship in it and also please share out the pbix file which does not contain sensitive data, it will help in solving your problem.

vjtianmsft_4-1723111492641.png

vjtianmsft_5-1723111527510.pngNote that the SUMMARIZE() function itself has a de-emphasis role, so there is no need to use distinctcount() again

I hope my suggestions give you good ideas, if you have any more questions, please clarify in a follow-up reply.

Best Regards,

Carson Jian,

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

9 REPLIES 9
Anonymous
Not applicable

Hello,@Ashish_Mathur ,@Daniel29195 ,thanks for your concern about this issue.

Your answer is excellent! And I would like to share some additional solutions below.
Hi,@Loreto-F .I am glad to help you.
You can refer to my test below
Here is my test data:

vjtianmsft_0-1723111226121.png

Since the filtering conditions you have given are not very specific, I have created a variety of scenarios to simulate the possible filtering conditions, and the results of the filtering of non-repeating counting

1. If you want to filter out the data range as follows, you can try the following measure2:

vjtianmsft_1-1723111256738.png

 

Measure 2 = 
VAR _table = SUMMARIZE('Table','Table'[Team TAG],'Table'[Team Number],'Table'[Repeated],'Table'[Name Rule],"ISZIMU",IFERROR(INT('Table'[Team Number]),0))
RETURN COUNTROWS(SUMMARIZE(FILTER(_table,'Table'[Repeated]<>1),'Table'[Team TAG]))

 

2. If you want to filter out the results as follows, you can try the following measure.

vjtianmsft_2-1723111309717.png

 

Measure = 
VAR _table = SUMMARIZE('Table','Table'[Team TAG],'Table'[Team Number],'Table'[Repeated],'Table'[Name Rule],"ISZIMU",IFERROR(INT('Table'[Team Number]),0))
RETURN COUNTROWS(SUMMARIZE(FILTER(_table,'Table'[Repeated]<>1&&([ISZIMU]=0||'Table'[Name Rule]=BLANK())),'Table'[Team TAG]))

 

3. If you only want to filter out records with 'Table' [Repeated] column <> 1, you can use measure3 below:

vjtianmsft_3-1723111360219.png

 

Measure 3 = 
VAR _table = SUMMARIZE('Table','Table'[Team TAG],'Table'[Team Number],'Table'[Repeated],'Table'[Name Rule],"ISZIMU",IFERROR(INT('Table'[Team Number]),0))
RETURN COUNTROWS(SUMMARIZE(FILTER(_table,'Table'[Repeated]=1&&('Table'[Team Number]<>BLANK()||[ISZIMU]<>0)),'Table'[Team TAG]))

 

If you can explain your filtering criteria in detail and explain the filtering relationship in it and also please share out the pbix file which does not contain sensitive data, it will help in solving your problem.

vjtianmsft_4-1723111492641.png

vjtianmsft_5-1723111527510.pngNote that the SUMMARIZE() function itself has a de-emphasis role, so there is no need to use distinctcount() again

I hope my suggestions give you good ideas, if you have any more questions, please clarify in a follow-up reply.

Best Regards,

Carson Jian,

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Syndicate_Admin
Administrator
Administrator

Thank you for your help, but the measurement has errors that I don't know, it didn't work.

Ashish_Mathur
Super User
Super User

Hi,

Drag this measure to a card visual

=calculate(countrows(Data),data[name rule]=blank()&&[repeated]<>1)

Hope this helps.


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

hello thanks for your help, but it didn't work either, the error is in the syntax =blank()

I tried changing blank to blank, but it didn't work either

Hi,

I have assumed that "name rule" and "repeated" are columns in the Data table. 


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

Exactly

I will need to see the file. Share the download link. Show the problem very clearly.

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

@Syndicate_Admin 

 

 

assuming the table name is :  tbl 

 

 

create the following measure : 

 

_measure = 
var  ds = 
filter ( 

tbl , 

tbl[name rule] = blank() && tbl[repeated] <> 1 && isnumber( tbl[team number] ) 
)

 

return 

countrows( ds) 

 

let me know if this helps. 

 

Hello, thank you for your help. I adapted it until Power BI validated it, but it throws "(blank)" at me. the same with the previous solution.

Helpful resources

Announcements
PBIApril_Carousel

Power BI Monthly Update - April 2025

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

Notebook Gallery Carousel1

NEW! Community Notebooks Gallery

Explore and share Fabric Notebooks to boost Power BI insights in the new community notebooks gallery.

April2025 Carousel

Fabric Community Update - April 2025

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