After making some searches that didn't lead to anything useful for me, I would like to ask you this question.
Some background: I would like to create an oracle table via two different methods in order to compare performances. Actually I want to copy a table from one of my local SAS libraries to Oracle.
I used a first method (that works perfectly) with a libname to oracle:
LIBNAME dblib ORACLE USER=usr PASSWORD="&dbpwd_sas" PATH="DM_CT_TEST" SCHEMA="SAS";
PROC SQL NOPRINT;
CREATE TABLE dblib.TEST_WIN7 AS SELECT *
FROM SASHELP.CARS
WHERE STRIP(UPCASE(make)) EQ "ACURA"
;
QUIT;
LIBNAME dblib CLEAR;
But I also try to use another method via SQL pass-through that doesn't work:
PROC SQL NOPRINT;
CONNECT TO ORACLE (USER=usr PASSWORD="&dbpwd_sas" PATH="DM_CT_TEST");
EXECUTE ( CREATE TABLE sas.TEST_WIN7 AS
SELECT * FROM SASHELP.CARS
WHERE STRIP(UPCASE(make)) EQ "ACURA"
) BY ORACLE;
DISCONNECT FROM ORACLE;
QUIT;
With this method, SASHELP.cars is not found by the procedure.
So here is my question: Is it possible to copy a local SAS table into oracle via an SQL pass-through? If yes, how to proceed.
Thank you