cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Highlighted
Frequent Visitor

Connecting PowerBI-Dataflow to Sharepoint Online List

Hello,

 

In PowerBI-Desktop, I connect to files strored in SharePoint folders using the SharePoint folder connector.

 

I edit the "source" set of the query from SharePoint.Files() to SharePoint.Contents().

 

The only SharePoint online connectors available in Dataflow appear to be SharePoint lists and I am not able to connect to the discrete files stored wihtin SharePoint folders as I could using PowerBI desktop.

 

Is there any advise or direction on how I could connect PowerBI-Dataflow to files saved in SharePoint folders??

 

Thanks in advance.

 

Braden.

1 ACCEPTED SOLUTION

Accepted Solutions
Highlighted
Super User IV
Super User IV

Re: Connecting PowerBI-Dataflow to Sharepoint Online List

Hi there

I would suggest connecting to your data in SharePoint using Power BI Desktop and the query editor.

Once that is working, go into the advanced editor and copy the code. Then in the data flows, create a new blank query and paste the code in there.

You then should be able to see your data.




Did I answer your question? Mark my post as a solution!

Proud to be a Super User!







Power BI Blog

View solution in original post

5 REPLIES 5
Highlighted
Super User IV
Super User IV

Re: Connecting PowerBI-Dataflow to Sharepoint Online List

Hi there

I would suggest connecting to your data in SharePoint using Power BI Desktop and the query editor.

Once that is working, go into the advanced editor and copy the code. Then in the data flows, create a new blank query and paste the code in there.

You then should be able to see your data.




Did I answer your question? Mark my post as a solution!

Proud to be a Super User!







Power BI Blog

View solution in original post

Highlighted
Frequent Visitor

Re: Connecting PowerBI-Dataflow to Sharepoint Online List

Thanks GilbertQ,

Your recommendation seems to work a treat.

Cheers.

Highlighted
Super User IV
Super User IV

Re: Connecting PowerBI-Dataflow to Sharepoint Online List

Awesome, glad it is now working for you!




Did I answer your question? Mark my post as a solution!

Proud to be a Super User!







Power BI Blog

Highlighted
Frequent Visitor

Re: Connecting PowerBI-Dataflow to Sharepoint Online List

Hi, 
That query works in desktop:


let
Source = SharePoint.Contents("https://magentatec.sharepoint.com/sites/magenta-crm-group/", [ApiVersion = 15])
in
Source

But when copied into the dataflows throws a mistake "Unable to create OAuth connection. Reason: "Unexpected error""
Signing In with Microsoft account, both in desktop and dataflows. 

 

Any ideas how to fix it, please?

 

Highlighted
Frequent Visitor

Re: Connecting PowerBI-Dataflow to Sharepoint Online List

Hello, I get the same problem : 

1) copying the M code from PwBI desktop to Dataflow editor :

 

let
Source = SharePoint.Files("https://mytenantname.sharepoint.com/FOLDERNAME", [ApiVersion = 15]),
#"Lignes filtrées" = Table.SelectRows(Source, each ([Name] = "myexcelfile.xlsx"))
in
#"Lignes filtrées"

 

 

2) Trying to connect to sharepoint folder using "Microsoft" authentification :

a pop-up appear and while the Mirosoft user to selectappear in the pop-up, the powerbi window gave an error "Connexion cancelled"

 

What's wrong ?

 

Regards.

Helpful resources

Announcements
August 2020 Community Challenge: Can You Solve These?

August 2020 Community Challenge: Can You Solve These?

We're excited to announce our first cross-community 'Can You Solve These?' challenge!

Community Blog

Community Blog

Visit our Community Blog for articles, guides, and information created by fellow community members.

Upcoming Events

Upcoming Events

Wondering what events you could join or have an event to promote yourself? Check out our Upcoming Events.

Get Ready for Power BI Dev Camp

Get Ready for Power BI Dev Camp

We are thrilled to announce we will begin running a monthly webinar series named Power BI Dev Camp.

Top Kudoed Authors