Hello everyone,
I am trying to insert something to different oracle database from my SAS dataset.
As usual, the syntax of selecting table from other database is
select * from otherowner.tablename;
Let say I have a SAS dataset aaa.
proc sql noprint;
connect to oracle
(user=xxx password=xxx path=xxx);
execute (insert into otherowner.tablename select * from work.aaa) by oracle;
disconnect from oracle;
quit;
It seems that SAS seek "otherowner" as libname to operate the above statement.
Meanwhile, I have tried to add preserve_comments, i.e,
proc sql noprint;
connect to oracle (user=xxx password=xxx path=xxx preserve_comments=YES);
execute (insert into /*otherowner.tablename */ select * from work.aaa) by oracle;
disconnect from oracle;
quit;
However, this is also not working.
Could any expert advise how to implement what I want to execute. Many thanks.