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
SAS Super FREQ

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
SAS Super FREQ
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

sas-innovate-2024.png

Don't miss out on SAS Innovate - Register now for the FREE Livestream!

Can't make it to Vegas? No problem! Watch our general sessions LIVE or on-demand starting April 17th. Hear from SAS execs, best-selling author Adam Grant, Hot Ones host Sean Evans, top tech journalist Kara Swisher, AI expert Cassie Kozyrkov, and the mind-blowing dance crew iLuminate! Plus, get access to over 20 breakout sessions.

 

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.

Click image to register for webinarClick image to register for webinar

Classroom Training Available!

Select SAS Training centers are offering in-person courses. View upcoming courses for:

View all other training opportunities.

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