BookmarkSubscribeRSS Feed
deleted_user
Not applicable
I'm trying to insert into a SQL Server table from SAS SPDS table using proc sql.
It is running, but very slow.

~35 million records (~5 GB datasize) in 5 hours.
connection is via ODBC

Is there anything I can tune to make it go faster?


========================== code ==========================
/*****************/
/* SAS SPDS Libs */
/*****************/
LIBNAME src sasspds host="sas01" serv="5190" user="spdsadm" ip=yes schema= "SRC" password="XXXX" compress=yes;

/*****************/
/* SAS SPDS Libs */
/*****************/
libname SQL ODBC dsn=DWSQLServer user=sas password=XXXX schema=dbo;

%let spdssize = 49376m;

%let path=./logs;
%let LogFile="&path/post_insert_prod_model_scores_to_sql.log";
%let LstFile="&path/post_insert_prod_model_scores_to_sql.lst";

Proc printto log=&LogFile print=&LstFile new; run;

options obs=max;

proc sql;

insert into sq.stg_model_score
(id,
model_output_id,
model_score,
model_decile_level,
source_id,
score_date,
scored_by
)
select
id,
model_output_id,
model_score,
model_decile_level,
source_id,
model_scored_date,
model_scored_by
from source.SCORE_PROD_OUTPUT;

run;

quit;
2 REPLIES 2
ChrisNZ
Tourmaline | Level 20
Have you tried the BULKLOAD= and BULKCOPY= options?
deleted_user
Not applicable
support helped.

bulkload= is not available on UNIX
insertbuff= works!

thanks

sas-innovate-2024.png

Join us for SAS Innovate April 16-19 at the Aria in Las Vegas. Bring the team and save big with our group pricing for a limited time only.

Pre-conference courses and tutorials are filling up fast and are always a sellout. Register today to reserve your seat.

 

Register now!

What is Bayesian Analysis?

Learn the difference between classical and Bayesian statistical approaches and see a few PROC examples to perform Bayesian analysis in this video.

Find more tutorials on the SAS Users YouTube channel.

Click image to register for webinarClick image to register for webinar

Classroom Training Available!

Select SAS Training centers are offering in-person courses. View upcoming courses for:

View all other training opportunities.

Discussion stats
  • 2 replies
  • 1825 views
  • 0 likes
  • 2 in conversation