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
DeBIe
Post Partisan
Post Partisan

Refreshing with stored procedures

Hello everybody,

 

I'm about to implement a new Stored Procedure into PowerBI, but theres an additional requirement andI dont know yet how to approach that requirement.

 

It is possible to give 2 parameters for the stored procedure: Year and Month. If I leave the parameters empty, then it will return me the results for the current month only. What I need is to show the results of the entire last year (including current month). The stored procedure(query) is quiete heavy on the performance part, so what I would like to know if I can gather the data from previous months once, and refresh the data from the current month on daily basis.

 

What I was thinking was to create a duplicate query in PowerBI and connect to the SP twice. In one query I set the previous 11 months manually and then disable the report refresh functionality. And the other query I would leave the parameters empty. Then I would merge the two SP's into one. Problem is that I can't make the parameter dynamic like: Previous Months(11). I will need to fill in the numbers of the months.

 

Any thoughts?

1 REPLY 1
amitchandak
Super User
Super User

@DeBIe , there was a Trick show by Guyinacube in this video, I think a modified version of that may help you, see if that can help

https://www.youtube.com/watch?v=_zYvybVMk7k

Share with Power BI Enthusiasts: Full Power BI Video (20 Hours) YouTube
Microsoft Fabric Series 60+ Videos YouTube
Microsoft Fabric Hindi End to End YouTube

Helpful resources

Announcements
November Power BI Update Carousel

Power BI Monthly Update - November 2025

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

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!

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