Monthly Archives: October 2009

Loading
loading..

Putting tables from Oracle into SAS

If you are interested, the following SAS codes can help you import tables from Oracle into SAS.

 

/*get two tables from Oracle*/
rsubmit;
%macro recent(dsnin1=,dsnout1=,vars=);
proc sql stimer noerrorstop;
%include ‘~/connect.dssp’;
%put &sqlxmsg;

create table &dsnout1 as
select * from connection to ora (
select &vars
from
&dsnin1);
disconnect from ora;
quit;
%mend recent;

options nomlogic nomprint;
%recent(dsnin1=orcale_schma_name1.table_name,dsnout1=new_table_name1,vars=*);
%recent(dsnin1=orcale_schma_name2.table_name,dsnout1=new_table_name2,vars=*);

endrsubmit;

Layout mode
Predefined Skins
Custom Colors
Choose your skin color
Patterns Background
Images Background