All,
I have "=" and ":" signs in the S3 bucket , when I try to read it I am getting below error. Please can you suggest.
ERROR: Relative pathnames are not allowed.
NOTE: The SAS System stopped processing this step because of errors.
NOTE: PROCEDURE S3 used (Total process time):
real time 0.05 seconds
cpu time 0.02 seconds
proc s3
awsconfig="&config."
awscredentials="&creds." ;
list "&bucket./date=2021-09-19/time=09:20/" ;
run;
What is contained in macro variable &bucket?
Run
%put "&bucket.";
and post the log from that.
Given that you have a UNIX behind AWS, I would strongly recommend to not use characters like the equal sign and the colon in file/directory names.
The ERROR complains about a relative path, usually pointing to a missing forward slash at the start of the path; since you seem to have that, it might be that the equal sign or the colon causes S3 to expect another slash.
any idea about URLcodes for sas. I need for "=" and ":".
https://documentation.sas.com/doc/en/vdmmlcdc/1.0/lefunctionsref/p19ckwqexa3ir8n19hbvcz73lhmj.htm
If I use URLCODE like this , there is no ERROR but not listing the content in that bucket.
proc s3
awsconfig="&config."
awscredentials="&creds." ;
list "&bucket./date%3D2021-09-19/time%3D09%3A20/" ;
run;
If you want to know the hexcodes for those characters use the $HEX format.
You might also try using \ character to "escape" the equal sign and colon.
Might be best to open a ticket with SAS support to ask them how PROC S3 is supposed to represent names like that.
Are you ready for the spotlight? We're accepting content ideas for SAS Innovate 2025 to be held May 6-9 in Orlando, FL. The call is open until September 25. Read more here about why you should contribute and what is in it for you!
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.