Hi. In a sql data source, I want to extract a table with 4 columns with PROC SQL. But with a constrain. this constrain is a table (name: sleutel) with one column (name: sleutel2) which is stored in my laptop. This is my code. But it does not work. could you please help me?
data IA_data;
set work.sleutel;
run;
PROC SQL;
select ia.sleutel2
from IA_data ia;
CONNECT TO ODBC AS mycon (datasrc=IA_P);
select *
FROM CONNECTION TO mycon
(SELECT
column1,
column2,
column3,
column4
FROM ia_treinrit trr
where
column1 = ia.sleutel2
);
run;
DISCONNECT FROM mycon;
QUIT;