BookmarkSubscribeRSS Feed
annypanny
Quartz | Level 8

I have two codes casestudy1 and casestudy2 with same libname.

libname sas "c:\mysaslib" access=readonly;

 

now I want to append a table final1 of casestudy1:

proc transpose data = fp
out = final1
by Scheme name;
var performance;
run;

 

with another table final 2 of casestudy2:

proc transpose data = perf
out = final2;
by Number name;
var performance;
run;

 

 

I have done the coding in casestudy2 as,

Data final_perf;
set sas.final1;
run;

proc append base-final1 data=final2;

run;

 

but getting error as final1 does not exist.

How can I solve this issue?

 

 

5 REPLIES 5
Kurt_Bremser
Super User

There seems to be an ERROR in your first step, so final1 is not created. If that is not the case, make sure that all this runs in one session with one WORK.

 

Post your whole log of all these steps if you still have problems.

annypanny
Quartz | Level 8

24 Data final;
25 set sas.final1;
ERROR: File SAS.FINAL1.DATA does not exist.
26 run;

NOTE: Compression was disabled for data set WORK.FINAL because compression overhead would increase the size of the data set.
NOTE: The SAS System stopped processing this step because of errors.
WARNING: The data set WORK.FINAL may be incomplete. When this step was stopped there were 0 observations and 0 variables.
WARNING: Data set WORK.FINAL was not replaced because this step was stopped.

Jagadishkatam
Amethyst | Level 16

Seems like you are not saving the final1 in sas library, you need to update the proc transpose step to use out=sas.final1 to again use the sas.final1 in later steps.

 

proc transpose data = fp
out = sas.final1
by Scheme name;
var performance;
run;
Thanks,
Jag
biopharma
Quartz | Level 8
Problem is here.
Data final_perf;
*set sas.final1; /* wrong */
set final1 ; /* you have saved FINAL1 to the work library */
run;

sas-innovate-2024.png

Available on demand!

Missed SAS Innovate Las Vegas? Watch all the action for free! View the keynotes, general sessions and 22 breakouts on demand.

 

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
  • 5 replies
  • 642 views
  • 1 like
  • 4 in conversation