- Mark as New
- Bookmark
- Subscribe
- Mute
- RSS Feed
- Permalink
- Report Inappropriate Content
Hi
I have one situation. I have one dataset, in this dataset one column is there containing all links like
When I am getting the output in excel or HTML from at from SAS code, I am getting the data in that particular column as normal data, but I need that data in Hyperlink format.
Can you help me how can I get that. What ods format I can use to get that. I need that code in PROC REPORT actually. To print the data I am using PROC REPORT.
Situation is little bit urgent, expecting quick help.
Regards
Sourav
Accepted Solutions
- Mark as New
- Bookmark
- Subscribe
- Mute
- RSS Feed
- Permalink
- Report Inappropriate Content
I have used this code
ods html file="/var/opt/data/data_project/sas94/bire/redwh/data/tmp/temp.html" ;
PROC REPORT DATA=FINAL_REPORT;
COLUMN DATA_DICT_LINK;
DEFINE DATA_DICT_LINK / DISPLAY "Wiki Link" ;
compute DATA_DICT_LINK ;
href=trim(DATA_DICT_LINK)||".html";
call define(_col_, "URL", href);
endcomp;
run;
I have tried with URLP and URB also but not getting the link in proper way, which been mentioned in side the column. I mean to say exact link is not opening. When clicking on that hyperlink from excel output.
Regars
Sourav
ods html close;
- Mark as New
- Bookmark
- Subscribe
- Mute
- RSS Feed
- Permalink
- Report Inappropriate Content
It looks like you're missing the appropriate tags in your data set variable - this works for me, for example
data test;
link = "<a href='https://www.sas.com/en_us/home.html'>SAS</a>";
run;
ods html body="/folders/myshortcuts/Dropbox/test.html";
proc print data=test;
run;
ods html close;
- Mark as New
- Bookmark
- Subscribe
- Mute
- RSS Feed
- Permalink
- Report Inappropriate Content
Thank
I am using proc report there in my project. Anything you can suggest there. For that column. To get all the link from that column as hyperlink.
Regards
Sourav
- Mark as New
- Bookmark
- Subscribe
- Mute
- RSS Feed
- Permalink
- Report Inappropriate Content
also in that column I have many links. How can I hyperlink that.
Regards
Sourav
- Mark as New
- Bookmark
- Subscribe
- Mute
- RSS Feed
- Permalink
- Report Inappropriate Content
I have used this code
ods html file="/var/opt/data/data_project/sas94/bire/redwh/data/tmp/temp.html" ;
PROC REPORT DATA=FINAL_REPORT;
COLUMN DATA_DICT_LINK;
DEFINE DATA_DICT_LINK / DISPLAY "Wiki Link" ;
compute DATA_DICT_LINK ;
href=trim(DATA_DICT_LINK)||".html";
call define(_col_, "URL", href);
endcomp;
run;
I have tried with URLP and URB also but not getting the link in proper way, which been mentioned in side the column. I mean to say exact link is not opening. When clicking on that hyperlink from excel output.
Regars
Sourav
ods html close;
- Mark as New
- Bookmark
- Subscribe
- Mute
- RSS Feed
- Permalink
- Report Inappropriate Content
At last it worked for me. I have just removed
||".html";
this part from the code, because my link was tiny link. For tiny link it was not working. For other link it will work.
Thanks