Supplies are limited. Contact info@espc.tech right away to save your spot before the conference sells out.
Get your discountScore big with last-minute savings on the final tickets to FabCon Vienna. Secure your discount
My coworker shared a CSV with me in a Teams chat just betwen the two of us. I want to connect to that file in Power BI without having to download the file to my local machine or save it in another location.
If I copy the link using the ellipsis dropdown, I get a link like
https://companyname-my.sharepoint.com/:x:/g/personal/johndoe_companyname_com/EYDht2QiGxhMqx4lQuznf_YB9C3CPf691EYZIMgrjvYw_Q?e=v68gGn
If I open it in Excel, the location in the File > Info tab looks like
Doe, John's OneDrive - Company Name >> Documents >> Microsoft Teams Chat Files
I've tried various permutations of SharePoint and Web connections to no avail so far. Either I can't find the folder or it won't authorize me.
Edit: The following works if I paste it into my browser, but not in Power BI:
https://companyname-my.sharepoint.com/:x:/r/personal/johndoe_companyname_com/Documents/Microsoft%20Teams%20Chat%20Files/RawData_t.csv
I get this error using the web connector using Organizational account:"We were unable to connect because this credential type isn't supported for this resource. Please choose another credential type."
If I try SharePoint.Contents() with that URL in Power Query I get
"DataSource.Error: SharePoint: Request failed: The remote server returned an error: (400) Bad Request. (Bad Request)"
Solved! Go to Solution.
This works for me
let
Source = SharePoint.Files("https://<company>-my.sharepoint.com/personal/<user>", [ApiVersion = 15]),
CSV = Source{[Name="data.csv",#"Folder Path"="https://<company>-my.sharepoint.com/personal/<user>/Documents/Microsoft Teams Chat Files/"]}[Content],
#"Imported CSV" = Csv.Document(CSV,[Delimiter=",", Columns=2, Encoding=65001, QuoteStyle=QuoteStyle.None])
in
#"Imported CSV"
Make sure to clear credentials so you are not stuck with prior bad choices. Only works with OAuth2
Make sure they gave you access to that folder on their personal OneDrive.
What @lbendlin says. Teams links do not work, only the links that you get when you select "for people aleady having access" . You collegae has to go to their onedrive/sharepoint folder and 'manage access' to give you access first...
Try with a cleaned URL
https://companyname-my.sharepoint.com/personal/johndoe_companyname_com/EYDht2QiGxhMqx4lQuznf_YB9C3CPf691EYZIMgrjvYw_Q
That's one of the variations I've tried (I tried applying it at multiple levels too).
I get the following error:
"We couldn't authenticate with the credentials provided. Please try again."
This works for me
let
Source = SharePoint.Files("https://<company>-my.sharepoint.com/personal/<user>", [ApiVersion = 15]),
CSV = Source{[Name="data.csv",#"Folder Path"="https://<company>-my.sharepoint.com/personal/<user>/Documents/Microsoft Teams Chat Files/"]}[Content],
#"Imported CSV" = Csv.Document(CSV,[Delimiter=",", Columns=2, Encoding=65001, QuoteStyle=QuoteStyle.None])
in
#"Imported CSV"
Make sure to clear credentials so you are not stuck with prior bad choices. Only works with OAuth2
Make sure they gave you access to that folder on their personal OneDrive.
Thanks, @lbendlin!
I'm not sure exactly how/why this is different from the various things I was trying but I've verified that it does work for the scenario I described.