Hi All,
With the execution of below query
libname synapse sqlsvr user=xxxx pw=xxxx schema="xxxxxxx";'
data test_1 (compress=yes);
set synapse.test_1
run;
its, taking log time to get the table from SQl synapse table , also consuming too much space
Anyone who has experience similar issue and fixed it ?
Thanks,
Mushy
Regardless of use case, for analyzing performance you need to provide more information about your task. Like:
- Where does your SAS session executes (vs your Synapse instance).
- If SAS is on premises, what is your method of accessing Synapse (internet, direct route...)
- Have you possibility to tr another client tool to perform a similar operation?
- What is column definitions does your table have? I suspect you have some long varchar columns.
- Rerun the query and add the following options:
options msglevel=i sastrace=',,,d' nostsuffix sastraceloc=saslog fullstimer;
Please review optimization options for your libname statement, like READBUFF.
Hi,
A few questions so that more information is shared:
I have in the past worked at a site where compress = yes was the default system option, and based upon the log, the size would not necessarily always be reduced. So, perhaps try without the compress = yes option. You can test out various settings with a smaller amount of observations by using the obs= data set option, to reduce your testing time.
Thanks & kind regards,
Amir.
You will get more useful answers if you post the actual SAS log of your program including notes rather than posting code that contains a syntax error.
1)You could try some options of libname and proc sql.
options dbidirectexec bufno=100 bufsize=128k ; LIBNAME SQL ODBC DATAsrc=proddb SCHEMA=sas U SER=user PASSWORD="*******" INSERT_SQL=YES INSERTBUFF=32767 readbuff=10000 bulkload=yes dbcommit=10000 ; proc sql; create table test_1 as select * from sql.test_1; quit;
2) try Pass-through SQL.
proc sql; connect to odbc as MyODBCName (dsn="MyODBCName" user="username" password="password" readbuff=10000 ); create table test_1 as select * from connection to MyODBCName ( select * from sqlsrv.test_1) ) ; disconnect from MyODBCName ; quit;
Catch the best of SAS Innovate 2025 — anytime, anywhere. Stream powerful keynotes, real-world demos, and game-changing insights from the world’s leading data and AI minds.
Learn how use the CAT functions in SAS to join values from multiple variables into a single value.
Find more tutorials on the SAS Users YouTube channel.
Ready to level-up your skills? Choose your own adventure.