SAS Data Integration Studio, DataFlux Data Management Studio, SAS/ACCESS, SAS Data Loader for Hadoop and others

WARNING when using EXECUTE() to run Redshift COPY command

Reply
Super User
Super User
Posts: 7,932

WARNING when using EXECUTE() to run Redshift COPY command

Does anyone know how to stop PROC SQL from writing WARNING: line into SAS log when remote database sends back INFO message when using EXECUTE() statement in PROC SQL to push commands into the database?

 

I was using SAS/Access to ODBC with a Redshift database and issuing COPY command to load into a table from files on S3 bucket. The command runs fine, but I get a WARNING in the SAS log.

WARNING: During execute: INFO:  Load into table 'bucket_test' completed, 19 record(s) loaded
         successfully.

Is there some SAS option, PROC SQL option or ODBC connection option that will make PROC SQL not describe that note as a WARNING?  Or perhaps some Redshift option that could stop it from sending the status message back?

proc sql noprint ;
  connect to odbc .....;
  execute(
    copy &schema..&table
    from %squote(s3://&bucket/sas_upload&path/&fname)
    access_key_id &keyid  secret_access_key &secret
    delimiter '|'  gzip  csv
    blanksasnull  emptyasnull
    dateformat 'auto'  timeformat 'auto'
  ) by odbc;
quit;

 

PROC Star
Posts: 2,310

Re: WARNING when using EXECUTE() to run Redshift COPY command

Maybe

proc sql nowarn; 

would work?

Super User
Super User
Posts: 7,932

Re: WARNING when using EXECUTE() to run Redshift COPY command


@ChrisNZ wrote:

Maybe

proc sql nowarn; 

would work?


Good idea, but unfortunately it does not help.

PROC Star
Posts: 2,310

Re: WARNING when using EXECUTE() to run Redshift COPY command

Maybe a setting in the ODBC driver to not pass back messages then?

 

But the message is useful, not a warning, and SAS misinterprets it.

So it looks like it's time to raise a defect with tech support.

 

As a workaround for clean log, a quick proc printto may be necessary until the defect is fixed.

You can even read the log file right away and output the useful information back to the log. 

 

 

Ask a Question
Discussion stats
  • 3 replies
  • 154 views
  • 0 likes
  • 2 in conversation