user3642531
user3642531

Reputation: 319

Proc SQL output not showing

The my knowledge using Proc SQL should allow you to bypass the PRINT procedure and print the output automatically, but for some reason the output is not showing up. My output destination is active, and my log has no errors. This is my code.

proc sql;
    create table merged as
    select *
    from gram as g, nos as n
    where g.cash = n.weight;
quit;

The log just says the procedure time and the rows/variable count. No errors. But it's not showing up in the output window. I'm not sure what the issue is.

Upvotes: 3

Views: 5563

Answers (1)

Reeza
Reeza

Reputation: 21264

AFAIK SAS only outputs to the results window when you don't have a CREATE TABLE statement, though you can also suppress this with a NOPRINT option on the PROC SQL.

You can remove the create table statement or add a select to the proc to display your data:

proc sql;
create table merged as
select *
from gram as g, nos as n
where g.cash = n.weight;

select * from merged;
quit;

OR

proc sql;
select *
from gram as g, nos as n
where g.cash = n.weight;
quit;

Upvotes: 7

Related Questions