cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Richard_Halsall
Helper I
Helper I

Salesforce Object requiring an ID

Hi,

Please can somebody help.

I am attempting to connect to a specific Salesforce object named ContentDocumentLink

 

However this requires single or multiple id's to be passed so I get the error:

 

Richard_Halsall_0-1649671699717.png

 

I can create the list of ID's but don't know how to get the mquery to look at them and pass to the Salesforce object

 

Any help would be appreciated. Thanks

 

5 REPLIES 5
IfYouBuildIt
Frequent Visitor

Is anyone able to provide a more detailed answer to this? I am having the same problem but don't know M that well. I need to bring a table into Power BI that let's me associate an SFDC SNOTE to it's parent object.

 

Thank you!

amitchandak
Super User
Super User

@Richard_Halsall , try to append this after in

"(" & Text.Combine([List Parameter], ",") & ")"

 

or

 

"('" & Text.Combine([List Parameter], "','") & "')"



Power BI Features || Datamarts: https://youtu.be/8tskWsJTEpg || Field Parameters : https://youtu.be/lqF3Wa1FllE?t=70
Time Intelligence Decoded : https://youtu.be/aU2aKbnHuWs&t=145s || 50+Power Query List Functions : Learn Power Query List
Did I answer your question? Mark my post as a solution! Appreciate your Kudos !! Proud to be a Super User! !!
Dashboard of My Blogs !! Connect on Linkedin !! Subscribe to my youtube Channel !!
Want To Learn Power BI | Beginners !! Advance Concepts !! Power BI For Tableau User !!

Hi thanks, so I changed the syntax as suggested to this

 

let
Source = Salesforce.Data("https://login.salesforce.com/", [ApiVersion=48]),
ContentDocumentLink = Source{[Name="ContentDocumentLink"]}[Data]
in
"('" & Text.Combine([SFOpportunityID], "','") & "')"

 

and am now getting this error

 

Richard_Halsall_0-1649673263825.png

 

Hi, @Richard_Halsall 

 

You need to add the parameter to the correct position and not the end.  & means to combine strings.

 

Best Regards,
Community Support Team _ Janey
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

@v-janeyg-msft 
Can you explain what you mean by this.
Instead of:
let
Source = Salesforce.Data("https://login.salesforce.com/", [ApiVersion=48]),
ContentDocumentLink = Source{[Name="ContentDocumentLink"]}[Data]
in
"('" & Text.Combine([SFOpportunityID], "','") & "')"

what should the Advanced Editor look like?

Helpful resources

Announcements
September Update

Check it Out!

Click here to learn more about the September 2022 updates!

Power BI Dev Camp Session 26

Check it Out!

Mark your calendars and join us on Thursday, September 29 at 11a PDT for a great session with Ted Pattison!

Top Solution Authors