Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

The Power BI Data Visualization World Championships is back! It's time to submit your entry. Live now!

Reply
GopVan
Frequent Visitor

Point Power BI report to a different SharePoint list

When connecting the report to a SharePoint list, I provided the URL to the site, giving me a list of SharePoint lists to choose from.

 

The Advanced editor code looks like below:

 

Source = SharePoint.Tables(list_source, [Implementation="2.0", ViewMode="Default"]),
#"some-long-code-possibly-identifier" = Source{[Id="some-long-code-possibly-identifier"]}[Items]

 

list_source is a parameter containing the URL to the site.

I want the report to point to another list on the same site.  How can I parameterize the list name such that I can point the report to different lists quickly?

 

For now, I created a new connection to load the data from the new list and went to the Advanced Editor and got the ID of this list, and replace the old one with this.  Surely, there must be a more graceful way to do this.

 

 

3 REPLIES 3
GopVan
Frequent Visitor

Thank you for the answer @TomMartens   Instead of parameterizing the List ID, is there a way I can refer to the List by name or provide it as part of the URL?  The ID is an 8digit-4igit-4digit-4digit-12digit alphanumeric code. If I parameterize the ID, I still have to find out the ID for the list each time.

 

The only way I am able to find that ID is to connect to a list and get the ID from the Advanced Editor. Is there a straightforward way to get the List ID?   

Hey @GopVan ,

 

not that I know, as the List connector does not support a name property.
You can use Sharepoint to find the ID of the list, I assume that this is more simple than using Power Query . 

 

Regards,

Tom



Did I answer your question? Mark my post as a solution, this will help others!

Proud to be a Super User!
I accept Kudos 😉
Hamburg, Germany
TomMartens
Super User
Super User

Hey @GopVan ,

 

you can create parameters that store the identifiers Parameters - Power Query | Microsoft Learn

Create another paramater like pThisOrThat.
Then you can change the relevant queries like so

let
    ListParameter = if pThisOrThat = "this" then pList1 ... ,

    Source = ... ,
    theList = ...  ListParameter ... ,
    
    //from here you have to reference theList
    finalTransform = AnyTransform( theList , ...)

in
    finalTransform


Hopefully, this provides what you are looking for.

Regards,
Tom



Did I answer your question? Mark my post as a solution, this will help others!

Proud to be a Super User!
I accept Kudos 😉
Hamburg, Germany

Helpful resources

Announcements
FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.