BookmarkSubscribeRSS Feed
🔒 This topic is solved and locked. Need further help from the community? Please sign in and ask a new question.
Coa_sas
Calcite | Level 5

Hi all,

I am submitting the following code to Base SAS via MobaX on linux os.
%LET DATALOC = %str(sas_user/xxx/test_base);

OPTIONS MPRINT;

%MACRO IMPTFILE(DL,FN,DSNAME);

LIBNAME OUTPUT "&DL.";

FILENAME INF  "&FN.";

PROC CIMPORT LIBRARY = OUTPUT FILE = INF;
SELECT &DSNAME;
RUN;
%MEND;
RUN;


%IMPTFILE(&DATALOC.,&DATALOC./PERSON.XPT,PERSON);
RUN;

I am getting the following error, please help me
220  %IMPTFILE(&DATALOC.,&DATALOC./PERSON.XPT,PERSON);
MPRINT(IMPTFILE):   LIBNAME OUTPUT "sas_user/xxx/test_base";
NOTE: Library OUTPUT does not exist.
MPRINT(IMPTFILE):   FILENAME INF "sas_user/xxx/test_base/PERSON.XPT";

MPRINT(IMPTFILE):   PROC CIMPORT LIBRARY = OUTPUT FILE = INF;
MPRINT(IMPTFILE):   SELECT PERSON;
MPRINT(IMPTFILE):   RUN;

ERROR: Physical file does not exist, /sas_user/xxx/sas_user/xxx/test_base/PERSON.XPT.
NOTE: The SAS System stopped processing this step because of errors.
NOTE: PROCEDURE CIMPORT used (Total process time):
      real time           0.03 seconds
      cpu time            0.01 seconds

221  RUN;


1 ACCEPTED SOLUTION

Accepted Solutions
SASKiwi
PROC Star

Your folder definition doesn't look right to me. I would expect it to begin with "/" like /sas_user/xxx/test_base. Check your folder path on Linux to ensure it is correct.

View solution in original post

2 REPLIES 2
SASKiwi
PROC Star

Your folder definition doesn't look right to me. I would expect it to begin with "/" like /sas_user/xxx/test_base. Check your folder path on Linux to ensure it is correct.

Coa_sas
Calcite | Level 5

Thanks Kiwi, Its worked..appriciate for your quick reply.

sas-innovate-2024.png

Don't miss out on SAS Innovate - Register now for the FREE Livestream!

Can't make it to Vegas? No problem! Watch our general sessions LIVE or on-demand starting April 17th. Hear from SAS execs, best-selling author Adam Grant, Hot Ones host Sean Evans, top tech journalist Kara Swisher, AI expert Cassie Kozyrkov, and the mind-blowing dance crew iLuminate! Plus, get access to over 20 breakout sessions.

 

Register now!

How to Concatenate Values

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.

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
  • 922 views
  • 0 likes
  • 2 in conversation