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

Get Fabric Certified for FREE during Fabric Data Days. Don't miss your chance! Request now

Reply
Mattmcdowell_
Helper I
Helper I

merge queries and aggregating data

Hi All,

 

I am very new to PowerBI so bear with me. 

 

My datasource is a SQL server database. It's import that I am using directquery for the report that I am working on as I need to the report to be able to refresh instantly on the service.

 

For this report I need 4 tables from my database:

1. Item

2. Sales order lines

3. Production Order Lines

4. Item history

 

With the above tables I need two tables within my one report I am creating in the desktop tool. One for location A and one location B. I have sucesfully created the report for location A by using the "Item table" as a base query and merging queries from sales order lines, production order lines, and item history. When I merge a query I then use the aggregate function to sum one of the columns and it works great.  So for location A I have merged 3 queries onto the item query and aggregated the desired column and its data points each time. Great.

 

Now when I went to do the second table/report for location B - What I did was add new data sources again for all 4 tables and followed the same steps. Using the item table as a base I merged the item history table and aggregated, all good. But when I go to merge with the sales order lines and then aggregate the column from the sales order lines table I get the message "this query step is not supported by direct query, do you want to change all tables to import".

 

I don't get why because I did the same step 4 times for location A and once for location B.

 

What gives?

2 REPLIES 2
Anonymous
Not applicable

@Mattmcdowell_,

What join type do you choose in report B? In Directquery mode, only Left outer join kind is supported, you will get "This step results in a query that is not supported in DirectQuery mode" message when you choose other join types.

1.PNG

Regards,
Lydia

Mattmcdowell_
Helper I
Helper I

Work around was to re-write the report and then merge the two reports on a dashboard. Accomplished what I was after but am still curious why I couldn't do it in the same report.

Helpful resources

Announcements
Fabric Data Days Carousel

Fabric Data Days

Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!

October Power BI Update Carousel

Power BI Monthly Update - October 2025

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

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.

Top Solution Authors