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

Prepping for a Fabric certification exam? Join us for a live prep session with exam experts to learn how to pass the exam. Register now.

Reply
niyati_61
Helper III
Helper III

Power BI - Connecting to a Live Excel Doc Data Source

Hello @d_gosbell,

 

Currently I have this Live Excel Document - it refreshes the data when you click on the Refresh button, it directly takes the data from the company SQL database. And the the data gets refreshed in this Excel Doc.

niyati_61_0-1646292531447.png

After connecting this Excel Document through Get Data - Excel in Power BI. Now, when I click on the Refresh button in the Excel doc and it refreshes the data; I click on Refresh Preview in Power BI too, but it did not refresh the data in PBI?

 

How do you connect a live Excel sheet like that in Power BI so that the data refreshes when the excel refreshed too?

 

Also, how does this refreshing work in Power BI Desktop for report server?

 

Thanks in advance!

1 ACCEPTED SOLUTION
d_gosbell
Super User
Super User


@niyati_61 wrote:

How do you connect a live Excel sheet like that in Power BI so that the data refreshes when the excel refreshed too?

 


It's actually better to not do this at all. The "Get Data" in Excel is using the same Power Query engine that Power BI uses (although a much older version). So the best approach is to edit the query in Excel, go into the advanced view, then copy all the text. Then go into Power BI, create a new blank query, go into advanced view and replace the text that is in there with the text you copied from Excel. Then Power BI will be connected directly to SQL and you can cut out the need for the Excel file in the middle.

 

One of the problems with your current approach is that the Power BI Excel connector reads the contents of the Excel file off disk. So if you click refresh, but do not save the file then Power BI will read an old copy of the data. And Power BI just reads the contents of the Excel file. It does not know there is another query behind the data and it has no way of triggering the refresh button.

View solution in original post

1 REPLY 1
d_gosbell
Super User
Super User


@niyati_61 wrote:

How do you connect a live Excel sheet like that in Power BI so that the data refreshes when the excel refreshed too?

 


It's actually better to not do this at all. The "Get Data" in Excel is using the same Power Query engine that Power BI uses (although a much older version). So the best approach is to edit the query in Excel, go into the advanced view, then copy all the text. Then go into Power BI, create a new blank query, go into advanced view and replace the text that is in there with the text you copied from Excel. Then Power BI will be connected directly to SQL and you can cut out the need for the Excel file in the middle.

 

One of the problems with your current approach is that the Power BI Excel connector reads the contents of the Excel file off disk. So if you click refresh, but do not save the file then Power BI will read an old copy of the data. And Power BI just reads the contents of the Excel file. It does not know there is another query behind the data and it has no way of triggering the refresh button.

Helpful resources

Announcements
PBIApril_Carousel

Power BI Monthly Update - April 2025

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

Notebook Gallery Carousel1

NEW! Community Notebooks Gallery

Explore and share Fabric Notebooks to boost Power BI insights in the new community notebooks gallery.

April2025 Carousel

Fabric Community Update - April 2025

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