Dear all,
I need some help, I wish to extract some excel files from this website:
@Kurt_Bremser helped me some time ago with this solution:
filename ht temp;
proc http
url="https://www.destatis.de/DE/Themen/Laender-Regionen/Regionales/Gemeindeverzeichnis/Administrativ/Archiv/GVAuszugJ/31122020_Auszug_GV.xlsx;jsessionid=B4477D957BFAB0E007E62A86373ED7F9.live711?__blob=publicationFile"
out=ht
;
run;
proc import
datafile=ht
out=test
dbms=xlsx
replace
;
sheet="Onlineprodukt_Gemeinden";
run;
The problem I have now is I wish to extract all excel files which has a date 31.12.1999, 31.12.2000, 31.12.2001 ....... and so on till 31.12.2021
What can I add to the above code to accomplish this task?
Can anyone help please?
Please note:
What I realised in the url is that the name of the excel sheet also contains the date (see below in link, I have highlighted this in red)
"https://www.destatis.de/DE/Themen/Laender-Regionen/Regionales/Gemeindeverzeichnis/Administrativ/Arch...31122020_Auszug_GV.xlsx;jsessionid=B4477D957BFAB0E007E62A86373ED7F9.live711?__blob=publicationFile"
Please also note that the excel files might be found on different pages
It is not only about 12 files but about several from 1999 to 2021 and further years. I will still appreciate any help
It's doable but not as simple as your original question by any fashion. Scraping is a bit of guess and test and digging into the data.
https://blogs.sas.com/content/sasdummy/2017/12/04/scrape-web-page-data/
Yes, you are right, I believe it's not so easy, but maybe someone can help anyway
April 27 – 30 | Gaylord Texan | Grapevine, Texas
Walk in ready to learn. Walk out ready to deliver. This is the data and AI conference you can't afford to miss.
Register now and lock in 2025 pricing—just $495!
Still thinking about your presentation idea? The submission deadline has been extended to Friday, Nov. 14, at 11:59 p.m. ET.
Learn how use the CAT functions in SAS to join values from multiple variables into a single value.
Find more tutorials on the SAS Users YouTube channel.
Ready to level-up your skills? Choose your own adventure.