Convert T-SQL to Power Query

Posts: 1
Joined: Sun Aug 11, 2019 3:02 am

Convert T-SQL to Power Query

Postby tutuk28 » Sun Aug 11, 2019 3:06 am

How can I turn the next query en SQL:

SELECT Column1, Column2 FROM Table WHERE Column3 < 15

Into Power Query M?
I can only perform the first part:

= Table.SelectColumns(#"Table", {"Column1", "Column2"})

Thanks a lot!

Posts: 55
Joined: Thu Oct 19, 2017 12:57 pm

Re: Convert T-SQL to Power Query

Postby RamanaV » Mon Aug 12, 2019 3:13 pm


the following should help
#"Filtered Rows" = Table.SelectRows(#"Changed Type", each [Column3] < 20),
#"Removed Columns" = Table.RemoveColumns(#"Filtered Rows",{"Column3"})
Ramana Varanasi
Training and Office Manager
Excelerator BI Pty. Ltd.

Return to “Power Query”

Who is online

Users browsing this forum: No registered users and 1 guest