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
mda
Advocate I
Advocate I

Report with Excel data sources and gateway

I have a report with two data sources from Excel files. I also installed a Gateway on my local computer, and want to start using it, with a scheduled refresh.

 

At first, I've created two data sources on the gateway. Both of them have the same paths as in my Desktop report.
When I publish it to app.powerbi.com it worked well.

 

But after that, I wanted to have different data sources for Development and Quality Check reports.

So I created a parameter with a list of two values: "DEV' ad "QA".

And then I edited my data sources definition and append it to file names. I also added this sufixes to files on disk.
So now when I change the parameter, I'm changing file which I'm using. It is working on Desktop well.

After that, on the gateway, I've created new data sources - for each Excel two for DEV and QA. And again the path to files was the same. And it worked.

But I want to have those Excel files in separate directories. I also thought that only file name should match, so I removed that data sources from the gateway and created a new one with paths different from that form Desktop.

And after that I'm seeing that warning at app.powerbi.com:

 

You don't have any gateway installed or configured for the data sources in this dataset. Please install a new personal gateway or configure the data source for an existing data gateway.

 

So in my report, I've selected "Enter Data" and created a table with two columns: Parameter and Base Path. Base Path contains a full path to the directory where Excel files for the environment are located. I also created the function which returns me a path based on current value of environment parameter.

 

After that, I changed my data sources and they are loading Excel in this way:

Source = Excel.Workbook(File.Contents(GetBaseFolder() & "MyTestFile.xlsx"), null, true)

So I thought that with this solution, my file names can be the same but they can be placed in different directories, which I can read by my function. But after publishing that report to app.powerbi.com I'm getting:

 

You can't schedule refresh for this dataset because one or more sources currently don't support refresh.

 

It's very weird, I don't know what I changed. I also made a version which adds a suffix to file name, so they could be distinguished between environments, but it didn't work.
Also, all paths produced by concatenation base directory and file name are the same as in data source configuration.

 

Can anybody help me?

Marcin

4 REPLIES 4
v-huizhn-msft
Employee
Employee

Hi @mda,

It looks you installed On-premises gateway, please add the excel file in different directions as two data sources in gateway. And check if it works fine.

Best Regards,
Angelia

I was using two data sources, and files were in different directories.
I think that the problem was with functions usage. When I switch to parameters it starts to work.

And based on my test, it appears that matching is done by full file path, not by file name.

 

Can anyone point me a documentation where I can find rules about matching data sources defined at Desktop and Gateway?

Hi @mda,

Hope the following articles are helpful.

Power BI Desktop privacy levels
On-premises data gateway in-depth
 
Best Regards,
Angelia

Hi @v-huizhn-msft,

Hope the following articles are helpful.

Power BI Desktop privacy levels
On-premises data gateway in-depth


Unfortunately, there is nothing about matching data sources defined at Desktop and Gateway.

As I wrote before it seems that matching of files is done by file path.

 

Maybe someone from Microsoft should write an article about matching all kind of data sources?

 

Regards,

Marcin

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.

Top Solution Authors
Top Kudoed Authors