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

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
NuTek
Frequent Visitor

Web scraping a site that has dates in URL?

I would like to scrape the contents of a table on a web page.

The URL that is in the format:

     https://www.abc.org/research/stats/units_06_17

Where the 06 is the month and 17 is the year.

 

Is there a way to specify this for the  previous month using Power BI?

It look slike tere is a section for "HTTP request header parameters" but nothing 

striks me as someting I can use to format the above URL.

 

 

 

3 REPLIES 3
v-jiascu-msft
Employee
Employee

Hi @NuTek,

 

Could you please tell me if your problem was resolved? Could you please share the answer or mark the proper answer as solution if it's convenient for you? That will be a help to the others.

Best Regards!
Dale

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

It has not been resolved.  Closest answer seems to be to define report parameters, but that would prompt when the report is run and I want to automate the refresh using the Gateway.

v-jiascu-msft
Employee
Employee

Hi @NuTek,

 

Maybe you could try parameters.

1. Add a parameter. It's called "URL" in my test. There are three values. (Yours may be "units_04_17", "units_05_17", "units_06_17")Web scraping a site that has dates in URL.jpg

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

2. There will be a query when step 1 is done. Then connect to web source, select "Advanced". In the second part of URL, select parameter "URL".

 

Web scraping a site that has dates in URL2.jpg

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

3. Every time I changed the parameter, the table "table0" would retrieve data from the website.

 

Best Regards!

Dale

 

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

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

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