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

Earn the coveted Fabric Analytics Engineer certification. 100% off your exam for a limited time only!

Reply
elijah2018
Helper I
Helper I

HELP ! Importing data from changing url

Hello everyone, 

 

This is my very first message on a forum like this so if my question hard to understand or incomplete im sorry in advance. 

 

But here is the problem im dealing with. 

So the company im an intern in wants me to connect Power BI to their buisness. I have figured out how to download data from their API using the Desktop app, the thing is that it is about 40 tables i need and all have the same url string in the beginning it is only the end part that changes. 

They want me to try to download all data with just one call/query/click so i've read a lot of posts here about having a parameter in the URL, dynamic URL and so on. 

But from one of the post it seemed that I needed to first download one file and then edit so the last part of the URL is a parameter instead. But I want to define a parameter first and then by just one call download all the data into the different tables. 

 

As I'm typing this Q, I get that it might be hard to understand what I want or what the problem is, so let me see if I can give an example. 

 

Let's say I access the API with www.mydatasource.com/data/newdata and this takes me to a page that contains string like 

''sales'' 

''revenues''

''CostOfGodsSold'' etc and by adding one of those strings to the end of the URL it automatically downloads the data in a CSV file, i.e www.mydatasource.com/data/newdata/sales will download the sales data . 

 

So I wanna pass ''sales'', ''revenues'' and ''CostOfGodsSold'' as parameters when I first start Power BI desktop and then for Power BI to save all the data into separate tables. 

 

Thank you for your help in advance 

 

Best regards 

Elijah

1 ACCEPTED SOLUTION
Stachu
Community Champion
Community Champion

this article should help
https://blog.crossjoin.co.uk/2016/05/15/creating-m-functions-from-parameterised-queries-in-power-bi/

 



Did I answer your question? Mark my post as a solution!
Thank you for the kudos 🙂

View solution in original post

1 REPLY 1
Stachu
Community Champion
Community Champion

this article should help
https://blog.crossjoin.co.uk/2016/05/15/creating-m-functions-from-parameterised-queries-in-power-bi/

 



Did I answer your question? Mark my post as a solution!
Thank you for the kudos 🙂

Helpful resources

Announcements
April AMA free

Microsoft Fabric AMA Livestream

Join us Tuesday, April 09, 9:00 – 10:00 AM PST for a live, expert-led Q&A session on all things Microsoft Fabric!

March Fabric Community Update

Fabric Community Update - March 2024

Find out what's new and trending in the Fabric Community.