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

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
alm5084
Helper II
Helper II

Poor Performance with Inner Joins

I am trying to limit the amount of editing I have to do when I update reports to include new periods. There are no date fields in the data sources where I am pulling, so the periods are chosen as a list. Currently, for every report dataset, I must go into every single query in a report and choose the same terms over and over again.

 

What I would like to do is create one new query where I can choose the periods to include one time, and inner join that query to all other queries in my file so I can edit one query and on refresh all queries will update to my new chosen items. The purpose of the inner join is to limit the rows on multiple queries to a list of options where I only have to choose the list items one time when I update and refresh a dataset.

 

It is essentially using the one query as a parameter for all other queries; I can't use an actual parameter because as far as I know parameters only support choosing one item at a time.

 

The problem is that this loads EXTREMELY slowly. I notice that when it is loading the total number of rows after merging should be around 600,000, but the query seems to be pulling every single row in that datasource and THEN performing the merge, because after about an hour or so the query stops and I end up with the right number of rows.

 

I posted in a similar thread about poor performance with inner joins when pulling data from Access but I guess that thread was about getting data from Access more than the issue with inner join performance.

 

Edit: I wanted to add that when I connect to the cube in Power Pivot and use the query designer, and I add a dimension to the filter area, all dimension categories are immediately available when I click the drop down. Whereas in Power BI it seems to query the entire fact table to find unique dimension categories. Why is Power Pivot able to interact with the same cube correctly while Power BI seems to need to scan the whole fact table every time I click anything?

7 REPLIES 7
CahabaData
Memorable Member
Memorable Member

I saw your post in the Access thread and another you posted several hours past that was not answered yet.  I see the commonality of your post is really about slow performance.

 

What I would do is a sanity check.  Verify your PBI Desktop install is 64bit and on a machine with a good amount of RAM.  Then I would start a brand new .pbix file with just 1 record set and do a Get Data load of it.  And do a time trial.

 

Incrementally time the load only by 1 data set at a time before setting up joins or Query Editor tasks  - then retime after query editing; and try and determine where is the key time delay experience.

www.CahabaData.com

My data sources are a SQL server database and an analysis services cube, both on premises. I am importing the data into the model.

 

I tried first with only one item from the selection list, and tried merging that with one other query. It took about 20 minutes to edit the query (in the query editor) and another 20 or 30  mintues to run. With that one selection it only pulls about 70,000 rows for the second query.

Hi @alm5084,

 

>> It took about 20 minutes to edit the query (in the query editor) and another 20 or 30  mintues to run. 

I'd like to suggest you import these tables and operated in power bi(re-create the relationships and merged in power bi), it may improve the performance.

 

Regards,

Xiaoxin Sheng

Community Support Team _ Xiaoxin
If this post helps, please consider accept as solution to help other members find it more quickly.

I have recreated the Power BI desktop file either 3 or 4 times, same issue each time.

Hi @alm5084,


You can refer to below formula which about improve the query performance.

How to improve tthe performance of query having more inner joins?

 

Regards,

Xiaoxin Sheng

Community Support Team _ Xiaoxin
If this post helps, please consider accept as solution to help other members find it more quickly.

It looks like v-shex-msft 's solution is about writing SQL queries. My questions is about using the query editor windows in Power BI against a cube and merging those queries together also using the query designer. There are no SQL queries.

Phil_Seamark
Employee
Employee

HI @alm5084

 

Are you currently using the Query Editory (Power Query) to do this work?  

 

What is your data source?


To learn more about DAX visit : aka.ms/practicalDAX

Proud to be a Datanaut!

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

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