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

Enhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends August 31st. Request your voucher.

Reply
Anonymous
Not applicable

Count Distinct Across Two tables works until I try and add a filter...

Hi

 

I have written a measure which allows me to countdistinct across two tables as follows;

 

JM TEST =
 
COUNTROWS (
    INTERSECT (
        VALUES ( 'Product List'[ProdID]),
        DISTINCT (
            UNION (
                VALUES ( 'Product List'[ProdID ),
                VALUES (Item List [Prod ID] )
            )
           
 
        )
    )
)
 
However, when I try and filter, I get an error message saying Function INTERSET does not support joining a column of type Integer with a column type of Text.
 
Any idea on what is going wrong or how I can add multiple filters to the measure?
 
Thanks
3 REPLIES 3
Dangar332
Super User
Super User

hi, @Anonymous 

hey joseph one of your column (Product List'[ProdID ) or (Item List [Prod ID] ) is text type so check it change it to interger or wholenumber

Anonymous
Not applicable

Hi

 

I have checked and they are text but they need to be text, how would I change this to allow me to filter on text?

hi, @Anonymous 

if you want  in text ffilter then change your Integer column to text

make your both columns ('Product List'[ProdID] ,List [Prod ID] ) to text form

 

Helpful resources

Announcements
July 2025 community update carousel

Fabric Community Update - July 2025

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

July PBI25 Carousel

Power BI Monthly Update - July 2025

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