Forum Discussion
jptarqu21
11 years agoNew Member
Force Query Join to be performed at the database?
When using the Query Editor, I selected two tables from my Sql server database. I tried doing a "merge queries" but it looks like instead of doing the join at the sql level (which executes realy fast...
ImkeF
10 years agoCommunity Champion
This article contains a lot of information about what is preventing query folding: https://www.mssqltips.com/sqlservertip/3635/query-folding-in-power-query-to-improve-performance/
One of it being writing your own SQL-statements - so don't use the SQL-editor!. Instead perform multiple steps by clicking the UI or the M-editor - most of them should fold.
I've experienced a bug when merging with non-SQL-tables. Created a workaround-solution that you can read here: http://www.thebiccountant.com/2015/09/17/filter-sql-server-queries-with-excel-tables-query-folding-limitations-and-bug-workaround/