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

Score big with last-minute savings on the final tickets to FabCon Vienna. Secure your discount

Reply
wokka
Helper IV
Helper IV

How to display data filtered from imported table

Hi

 

I have a SQL Server table that I have connected to my desktop powerbi ( it has a local model ).

 

The table appears as a dimension/table  called "AA_Data"  and has columns called  [ID]  and  [trace].

 

What I wanted to do is drag in both columns from AA_Data  into a simple table on the desktop , but filter the data so we can display only one part of the table data.  

 

So table looks like this as unfiltered data :

 

[ID]   [trace]

X      1

Y      2

Z      3

 

But I wanted to filter out everything except Y and display this :

 

[ID]   [trace]

Y      2

 

How could I do that please?

 

Thanks in advance

1 ACCEPTED SOLUTION
Ritaf1983
Super User
Super User

Hi @wokka 

Simple filter will do the job :

Ritaf1983_0-1747793406987.png

The pbix with the example is attached

If this post helps, then please consider Accepting it as the solution and giving Kudos to help the other members find it more quickly

Regards,
Rita Fainshtein | Microsoft MVP
https://www.linkedin.com/in/rita-fainshtein/
Blog : https://www.madeiradata.com/profile/ritaf/profile

View solution in original post

9 REPLIES 9
v-pnaroju-msft
Community Support
Community Support

Hi @wokka,

We have not received a response from you regarding the query and were following up to check if you have found a resolution. If you have identified a solution, we kindly request you to share it with the community, as it may be helpful to others facing a similar issue.

If you find the response helpful, please mark it as the accepted solution and provide kudos, as this will help other members with similar queries.

Thank you.

v-pnaroju-msft
Community Support
Community Support

Thankyou, @Ritaf1983@ryan_mayufor your response.

 

Hi @wokka,

 

We would like to check if the solution provided by @Ritaf1983 and @ryan_mayu has resolved your issue.

If you found the response helpful, please mark it as the accepted solution and add kudos. This recognition benefits other members seeking solutions to similar queries.
Should you have any further queries, kindly feel free to contact the Microsoft Fabric community.

 

Thank you.

Ritaf1983
Super User
Super User

Hi @wokka 

Simple filter will do the job :

Ritaf1983_0-1747793406987.png

The pbix with the example is attached

If this post helps, then please consider Accepting it as the solution and giving Kudos to help the other members find it more quickly

Regards,
Rita Fainshtein | Microsoft MVP
https://www.linkedin.com/in/rita-fainshtein/
Blog : https://www.madeiradata.com/profile/ritaf/profile

Hi

 

I am familiar with using filters on a page, what I wanted to know was how we would do it using DAX please?

Hi @wokka 

measure_ = CALCULATE(sum('Table'[trace]), FILTER('Table','Table'[id]="Y"))
Ritaf1983_0-1747796411945.png

The updated pbix is attached

If this post helps, then please consider Accepting it as the solution and giving Kudos to help the other members find it more quickly

Regards,
Rita Fainshtein | Microsoft MVP
https://www.linkedin.com/in/rita-fainshtein/
Blog : https://www.madeiradata.com/profile/ritaf/profile

I'm just wondering why use SUM if we only want to list ( not summing them ) any rows that have "Y" in [ID} column please? Or maybe I'm missing something about DAX use maybe?

 

In SQL I'd write this as :      Select * from AA_DATA where [ID] = 'Y'

Hi @wokka 

SQL is a query language.
Power BI is a data visualization platform.
The working logic between these two is fundamentally different.

For example, in Power BI, a table visual is the only one that fully supports displaying raw, non-aggregated values. Other visuals typically require aggregations.
Also, DAX is not a query language like SQL – it's designed primarily for creating calculations based on filter context within a data model.

Power BI is not a "report generator" in the same way SQL is used for retrieving rows from a database.
Instead, Power BI is model-driven. It relies on a semantic model, with filters and measures built on top of it.

So:

If you're trying to filter data at the report-wide level, this should be handled during the ETL phase, in Power Query.

If you're filtering for visual display only (not part of a calculation), then it's best to use slicers or built-in UI filters.

If you're insisting on handling this through DAX, there are some technical workarounds, for example:
Measure_ = IF(MAX('Table'[id]) = "Y", MAX('Table'[id]), BLANK())

Ritaf1983_0-1747799411285.png


But that’s not a best practice. It’s a workaround for very specific scenarios, and not how DAX is generally intended to be used.

P.S. I adjusted your table so that “Y” can now appear in more than one row.

The updated pbix is attched

If this post helps, then please consider Accepting it as the solution and giving Kudos to help the other members find it more quickly

Regards,
Rita Fainshtein | Microsoft MVP
https://www.linkedin.com/in/rita-fainshtein/
Blog : https://www.madeiradata.com/profile/ritaf/profile

Hi

 

Thanks for the extra info. Ive been kind of dropped into powerbi work, after many years in purely SQL. Its a matter of re-calibrating my headspace to work with the powerbi paradigm. 

 

What drives this is a need to be able to basically dump out data as needed, to be able to confirm data is as we would expect it to be.

 

Thanks. 

ryan_mayu
Super User
Super User

@wokka 

you can try to add a filter to visual,page or report 

https://learn.microsoft.com/en-us/power-bi/consumer/end-user-report-filter?wt.mc_id=DP-MVP-5004616

 





Did I answer your question? Mark my post as a solution!

Proud to be a Super User!




Helpful resources

Announcements
August Power BI Update Carousel

Power BI Monthly Update - August 2025

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

August 2025 community update carousel

Fabric Community Update - August 2025

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