For general information about this feature, see SQL Pass-Through Facility.
Here are the SQL pass-through facility specifics for the SAP HANA interface.
SAPHANA.SAPHANA alias is used.This example connects to SAP HANA and then disconnects from it.
proc sql noerrorstop;
connect to saphana as x1(server=mysrv1
port=30015 user=mysur1 password='mypwd1');
disconnect from x1;
quit;
This next example connects to SAP HANA, executes some SQL statements, and then disconnects from SAP HANA.
proc sql noerrorstop;
connect to saphana as x1(server=mysrv1
port=30015 user=mysur1 password='mypwd1'
execute (CREATE TABLE t1 (no int primary key, state varchar(10))) by x1;
execute (INSERT INTO t1 values (1, 'USA')) by x1;
execute (INSERT INTO t1 values (2, 'CHN')) by x1;
select * from connection to x1 (SELECT * FROM t1 ORDER BY no);
disconnect from x1;
quit;