BookmarkSubscribeRSS Feed
deleted_user
Not applicable
Can someone help me out?
What I would like to do is save the results of series of html statements into a variable.

i.e. save a proc tabulate into a variable that would include all the html code so I can store the html code into a database.

I imagine I could save the html file and then reread it with an input statement.

Any other ideas / suggestions ?
2 REPLIES 2
Cynthia_sas
SAS Super FREQ
Hi:
I'm confused by what you want to do. When you do this:
[pre]
ods html file='c:\temp\wombat.html';
code;
ods html close;
[/pre]
then you ARE creating an HTML file and yes, you could read that file with an INPUT statement.

What I think you want, If I understand you correctly, you want to save the whole ASCII TEXT HTML file as the value of a single variable in a database???? I guess what confuses me is the "series of HTML statements" part. Would you mean everything that's in the ODS HTML sandwich above??? OR, would you mean the RESULTS of running the statements above?? In the first case, that sounds like a source code management system and in the second case, that sounds like a document management system.

In either case, I'm not sure that saving the HTML results into a single data base variable would work, because databases frequently have limitations on the size that a text field can hold and inevitably, you'll bump into that limit if you're trying to save the entire HTML results. That might not be the case if you saved just the source code into a data base or source management system. At any rate, your best bet for help may be to contact SAS Tech Support, as they can zero in on exactly what you want to do and help you figure out a way to do it, if it's possible/feasible/do-able.

To find out how to contact Tech Support, refer to:
http://support.sas.com/techsup/contact/index.html

cynthia
deleted_user
Not applicable
>Would you mean everything that's in the ODS HTML sandwich above??? OR, would you mean the RESULTS of running the statements above??;

I mean the resuts, and yes therefore the ASCII text html generated by the series of ods statements. Or for that matter any ASCII text file.

I have seen [pre]put _infile_;[/pre] but am trying to figure out how to store that in a variable.

I am not concerned with the space limitations of my database field. I do this with some web based CMS systems I have developped.

I'll try Tech Support.

sas-innovate-2024.png

Join us for SAS Innovate April 16-19 at the Aria in Las Vegas. Bring the team and save big with our group pricing for a limited time only.

Pre-conference courses and tutorials are filling up fast and are always a sellout. Register today to reserve your seat.

 

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
  • 2 replies
  • 622 views
  • 0 likes
  • 2 in conversation