BookmarkSubscribeRSS Feed
anqi9103
Calcite | Level 5

Hi everyone, I am learning to using SAS this week.   Here is the problem I was stuck for a long time.

 

There is no log and result after I run the code in sas online studio. I have entered the username and password.

 

%let wrds=wrds.wharton.upenn.edu 4016;
options comamid=TCP remote=WRDS;
signon username=*** password="***";

rsubmit;


libname comp '/wrds/comp/sasdata/nam';
libname compc '/wrds/comp/sasdata/nam/company';
libname crsp '/wrds/crsp/sasdata/a_stock';
endrsubmit;

rsubmit;
proc sql; create table sas_try as select distinct gvkey, datadate, cogs, csho, ni, ppet, prcc_f
from comp.funda
where year(datadate)>=1986
order by gvkey, datadate;
quit;
proc print data=sas_try (obs=100);
run;
endrsubmit;

 

 

Hope someone can help me to solve it. Thank you so much!

 

 

4 REPLIES 4
anqi9103
Calcite | Level 5

There is no log and result after I run the code in sas online studio. 

 

I would like to extract some variables from comp.funda dataset and create a new table. But nothing was generated after running the syntax. So what's wrong with my syntax?

 

Thank you!

Reeza
Super User
WRDS has some tutorials. Have you tried one of their exact queries to ensure you're set up correctly? It's almost impossible to debug this without any log.
Amir
PROC Star

Hi,

 

Make sure the username and password are both correct and in the same case (upper / lower case) as what you should be using.

 

Should the the use of WRDS in the remote= option have an ampersand ('&') in front to refer back to the macro variable you set up earlier?

E.g:

 

options comamid=TCP remote="&WRDS";

as in the top of page 3 in the following paper:

 

https://support.sas.com/resources/papers/proceedings/proceedings/sugi30/023-30.pdf

 

 

Regards,

Amir.

hackathon24-white-horiz.png

The 2025 SAS Hackathon has begun!

It's finally time to hack! Remember to visit the SAS Hacker's Hub regularly for news and updates.

Latest Updates

Mastering the WHERE Clause in PROC SQL

SAS' Charu Shankar shares her PROC SQL expertise by showing you how to master the WHERE clause using real winter weather data.

Find more tutorials on the SAS Users YouTube channel.

Discussion stats
  • 4 replies
  • 966 views
  • 0 likes
  • 4 in conversation