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

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more

Reply
WLFRD
Helper III
Helper III

Limit import data from SQL based on date

Hello,

 

Last week, I have uploaded a report to the Power BI Workspace and the scheduled refresh is giving me some problems due to the large amount of data. 

I would like to modify this report by not importing all the SQL data (goes back to 2010) but just import  a rolling 18 months of data. 

 

I'm not sure how to do that in Power Query. Can someone help me out on this?

 

Thanks.

 

1 ACCEPTED SOLUTION
Anonymous
Not applicable

Hi @WLFRD ,

 

According to your statement, I know that your data source is SQL Server and you only need to load data in a rolling date range. Here I suggest you to try incremental refresh in Power BI. You need to configure it in Power BI Desktop. When your publish it and refresh in Power BI Service, the query filters return only those rows within the refresh period dynamically defined by the parameters. Those rows with a date/time within the refresh period are refreshed. Rows with a date/time no longer within the refresh period then become part of the historical period, which isn't refreshed. 

For reference: 

Configure incremental refresh and real-time data for Power BI datasets - Power BI | Microsoft Learn

Query folding guidance in Power BI Desktop - Power BI | Microsoft Learn

 

Best Regards,
Rico Zhou

 

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

1 REPLY 1
Anonymous
Not applicable

Hi @WLFRD ,

 

According to your statement, I know that your data source is SQL Server and you only need to load data in a rolling date range. Here I suggest you to try incremental refresh in Power BI. You need to configure it in Power BI Desktop. When your publish it and refresh in Power BI Service, the query filters return only those rows within the refresh period dynamically defined by the parameters. Those rows with a date/time within the refresh period are refreshed. Rows with a date/time no longer within the refresh period then become part of the historical period, which isn't refreshed. 

For reference: 

Configure incremental refresh and real-time data for Power BI datasets - Power BI | Microsoft Learn

Query folding guidance in Power BI Desktop - Power BI | Microsoft Learn

 

Best Regards,
Rico Zhou

 

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Helpful resources

Announcements
Power BI DataViz World Championships

Power BI Dataviz World Championships

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now!

December 2025 Power BI Update Carousel

Power BI Monthly Update - December 2025

Check out the December 2025 Power BI Holiday Recap!

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.