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

Earn the coveted Fabric Analytics Engineer certification. 100% off your exam for a limited time only!

Reply
Maddyqc
Frequent Visitor

Not able to filter

Hello,

As you can see, I am a newbie here. I am trying to make a table with tota cases (total rows) and total deaths in the same table. When I make separate tables, it works. When try to have them in the same table, it doesnt work. Your inputs are sincerely appreciated. Thank you

 

Filters.JPG

1 ACCEPTED SOLUTION
edhans
Super User
Super User

It is your data model. One of those tables isn't filtering the other. You can turn on crossfiltering by using something like this:

TEST =
CALCULATE(
    SUM( table2[field] ),
    CROSSFILTER ( table1[key], table2[key], BOTH )
)

But the fundamental issue is your model. You should have a star schema where your field in the table should be from a DIMENSION table that is filtering both of these FACT tables vs having the FACT tables filter one another. 



Did I answer your question? Mark my post as a solution!
Did my answers help arrive at a solution? Give it a kudos by clicking the Thumbs Up!

DAX is for Analysis. Power Query is for Data Modeling


Proud to be a Super User!

MCSA: BI Reporting

View solution in original post

4 REPLIES 4
Tahreem24
Super User
Super User

Are you using values from two different tables and try to put them in the same table visuals? If yes, so  check the relationship between those table.

 

Don't forget to give thumbs up and accept this as a solution if it helped you!!!

Please take a quick glance at newly created dashboards : Restaurant Management Dashboard , HR Analytics Report , Hotel Management Report, Sales Analysis Report , Fortune 500 Companies Analysis , Revenue Tracking Dashboard
edhans
Super User
Super User

It is your data model. One of those tables isn't filtering the other. You can turn on crossfiltering by using something like this:

TEST =
CALCULATE(
    SUM( table2[field] ),
    CROSSFILTER ( table1[key], table2[key], BOTH )
)

But the fundamental issue is your model. You should have a star schema where your field in the table should be from a DIMENSION table that is filtering both of these FACT tables vs having the FACT tables filter one another. 



Did I answer your question? Mark my post as a solution!
Did my answers help arrive at a solution? Give it a kudos by clicking the Thumbs Up!

DAX is for Analysis. Power Query is for Data Modeling


Proud to be a Super User!

MCSA: BI Reporting

Thank you, edhans.

Great @Maddyqc - can you please mark the respons as the "solution" so the thread can be marked done and future community users can see the solution that worked?



Did I answer your question? Mark my post as a solution!
Did my answers help arrive at a solution? Give it a kudos by clicking the Thumbs Up!

DAX is for Analysis. Power Query is for Data Modeling


Proud to be a Super User!

MCSA: BI Reporting

Helpful resources

Announcements
April AMA free

Microsoft Fabric AMA Livestream

Join us Tuesday, April 09, 9:00 – 10:00 AM PST for a live, expert-led Q&A session on all things Microsoft Fabric!

March Fabric Community Update

Fabric Community Update - March 2024

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