BookmarkSubscribeRSS Feed
Oleg_L
Obsidian | Level 7

Hello SAS-users.

How can i read .htm files into SAS dataset?

Is it possible?

Now I save .htm files as Excel and use proc import.

Is it the only way?

I use SAS 9.2

Thanks in advance.

Oleg.

10 REPLIES 10
Ksharp
Super User

Is it what you are looking for?

http://communities.sas.com/message/103590#103590

Ksharp

Oleg_L
Obsidian | Level 7

Thanks for your reply Ksharp.

But i can not open your link.

Oleg.

jonam
Calcite | Level 5

Sometime back i read an interesting article of my friend Pramod @

http://pramod-r.blogspot.com/2011/02/reading-table-from-website-into-sas.html

which describes in detail

Reading a table from a website into a SAS dataset

Hope this helps.

Oleg_L
Obsidian | Level 7

Thank you Jonam.

I will investigate your documentation.

Oleg.

SASJedi
Ammonite | Level 13

Oleg, I've written a workshop for SAS Users Groups called "Untangling the World Wide Web"   You can download a ZIP file containing the PDF and sample SAS code at http://goo.gl/oinmj

Check out my Jedi SAS Tricks for SAS Users
Cekola
SAS Employee

Hi @SASJedi, is that sample SAS code still aailable somewhere for download?

I'm looking for a way to import multiple html files and parse them using SAS, so maybe it would be helpful.

 

Thanks!

SASJedi
Ammonite | Level 13
Get "Untangling the World Wide Web" from my master links page
http://marksworld.net/jedi

Check out my Jedi SAS Tricks for SAS Users
Cekola
SAS Employee
Thank you so much!!!
art297
Opal | Level 21

HTML files can extend across numerous types, layouts, etc.  Did you have anything specific in mind?  Like trying to import a table from a page that you find on the web?

MikeZdeb
Rhodochrosite | Level 12

Hi ... Rick Langston has a couple of papers that might help with reading HTML files

and creating SAS data sets ...

Creating SAS® Data Sets from HTML Table Definitions

http://support.sas.com/resources/papers/proceedings09/052-2009.pdf

and ...

Handling Large Stream Files with the @'string' Feature

http://www2.sas.com/proceedings/forum2007/027-2007.pdf

hackathon24-white-horiz.png

2025 SAS Hackathon: There is still time!

Good news: We've extended SAS Hackathon registration until Sept. 12, so you still have time to be part of our biggest event yet – our five-year anniversary!

Register Now

How to Concatenate Values

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.

SAS Training: Just a Click Away

 Ready to level-up your skills? Choose your own adventure.

Browse our catalog!

Discussion stats
  • 10 replies
  • 15079 views
  • 1 like
  • 7 in conversation