Forum Discussion
ercwebdev
6 years agoFrequent Visitor
'Refresh Preview' hangs
This is pretty much a last effort to try and get this working. The M Power Query code below passes a URL to the sub routine, which then queries the PWA site to get List info. There are 93 Projects ...
Jimmy801
6 years agoCommunity Champion
Hello ercwebdev
try to change this code
let
Source = OData.Feed("https://xxxxxxxxxxx.sharepoint.com/sites/pwa/_api/ProjectData/Projects?$filter=ProjectWorkspaceInternalUrl ne null&$select=ProjectId,ProjectName,ProjectWorkspaceInternalUrl"),
#"Added Custom" = Table.AddColumn(Source, "siteURLFix", each let Source = [ProjectWorkspaceInternalUrl], uriPartsRecord = Uri.Parts(Source), result = uriPartsRecord[Scheme] & "://" & uriPartsRecord[Host] & uriPartsRecord[Path] in result),
#"AllListData" = Table.AddColumn(#"Added Custom", "Costs", each GetList([siteURLFix], "Costs")),
#"Removed Errors" = Table.RemoveRowsWithErrors(AllListData)
in
#"Removed Errors"
into this one
let
Source = Table.Buffer(OData.Feed("https://xxxxxxxxxxx.sharepoint.com/sites/pwa/_api/ProjectData/Projects?$filter=ProjectWorkspaceInternalUrl ne null&$select=ProjectId,ProjectName,ProjectWorkspaceInternalUrl")),
#"Added Custom" = Table.AddColumn(Source, "siteURLFix", each let Source = [ProjectWorkspaceInternalUrl], uriPartsRecord = Uri.Parts(Source), result = uriPartsRecord[Scheme] & "://" & uriPartsRecord[Host] & uriPartsRecord[Path] in result),
#"AllListData" = Table.Buffer(Table.AddColumn(#"Added Custom", "Costs", each GetList([siteURLFix], "Costs"))),
#"Removed Errors" = Table.RemoveRowsWithErrors(AllListData)
in
#"Removed Errors"
Hope this helps
If this post helps or solves your problem, please mark it as solution (to help other users find useful content and to acknowledge the work of users that helped you)
Kudoes are nice too
Jimmy
ercwebdev
6 years agoFrequent Visitor
Hi Jimmy,
Thanks for your reply. Yes I had tried Table.Buffer already (forgot to mention this) but it didn't yield any results.
So still looking for an answer!
Thanks
Alan
- jsreis5 years agoNew Member
Hello Alan -
Have you found a solution to your problem? It sounds identical to what I'm experiencing.
Any help will be greatly appreciated as I've spent countless hours trying to figure this out.
Thanks!
Jeff