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

Join us for an expert-led overview of the tools and concepts you'll need to become a Certified Power BI Data Analyst and pass exam PL-300. Register now.

Reply
Anonymous
Not applicable

SQL query to DAX or new table

Hello All,

 

I have a created a table as below m query

 

let
    Source = Table.FromRows(Json.Document(Binary.Decompress(Binary.FromText("i45WSlTSUQKiqqoqIJmaCuGB6YwMpVidaKUkIDMFIpwCotPSYKz0dLCCZCATjIEASJWUQKR0lBJBZhcVgRWB1KeCTUa2AoRiYwE=", BinaryEncoding.Base64), Compression.Deflate)), let _t = ((type text) meta [Serialized.Text = true]) in type table [A = _t, B = _t, C = _t, D = _t, E = _t, F = _t, G = _t]),
    #"Changed Type" = Table.TransformColumnTypes(Source,{{"A", type text}, {"B", type text}, {"C", type text}, {"D", type text}, {"E", type text}, {"F", type text}, {"G", type text}})
in
    #"Changed Type

Now i am trying to filter this table as based on column A values.

 

In SQl we can write the query as

 

select B,C,D from Table1 where A="a";

 

i tried to get this by new table option in power bi desktop modeling tab.

i have tried the below query

Table = CALCULATETABLE(VALUES(Table1[C]) ,FILTER(Table1,Table1[B]="d"))

By this query i am getting the single column from Table1 table.

But i need to get B,C,D column values also.

 

How can i get this done.

 

Any suggestions,

Mohanv V

1 ACCEPTED SOLUTION
Anonymous
Not applicable

Gota Solution on my own.

 

Q1 = CALCULATETABLE(SUMMARIZE('Table','Table'[B],'Table'[C],'Table'[D]),FILTER('Table','Table'[A]="a"))

View solution in original post

1 REPLY 1
Anonymous
Not applicable

Gota Solution on my own.

 

Q1 = CALCULATETABLE(SUMMARIZE('Table','Table'[B],'Table'[C],'Table'[D]),FILTER('Table','Table'[A]="a"))

Helpful resources

Announcements
Join our Fabric User Panel

Join our Fabric User Panel

This is your chance to engage directly with the engineering team behind Fabric and Power BI. Share your experiences and shape the future.

June 2025 Power BI Update Carousel

Power BI Monthly Update - June 2025

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

June 2025 community update carousel

Fabric Community Update - June 2025

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