BookmarkSubscribeRSS Feed
RebeccaJW
Calcite | Level 5

Hello,

 

I want to merge two datasets as shown below. 

data sub;
	set orig;
	where name="speech";
run;
data main;
	merge sub(in=a) orion.play(in=b);
	by actor;
	if a and b;
run;

If I just run the code above, there is an error saying ERROR: BY variables are not properly sorted on data set WORK.SUB.

 

However, if i sort the data as below:

proc sort data=sub out=sub;
	by actor;
run;

There are still errors saying  

ERROR: Insufficient space in file WORK.'SASTMP-000000713'n.UTILITY.
ERROR: File WORK.'SASTMP-000000713'n.UTILITY is damaged. I/O processing did not complete.
 
Can anyone help me? Thanks!
3 REPLIES 3
PaigeMiller
Diamond | Level 26

How big are these data sets?

--
Paige Miller
RebeccaJW
Calcite | Level 5
There are almost 70000 rows and 8 columns in the data set.
Ksharp
Super User

Are you using SAS University Edition?

Try option TAGSORT .

 

proc sort data=sub out=sub  tagsort ;
	by actor;
run;

Catch up on SAS Innovate 2026

Dive into keynotes, announcements and breakthroughs on demand.

Explore Now →
Develop Code with SAS Studio

Get started using SAS Studio to write, run and debug your SAS programs.

Find more tutorials on the SAS Users YouTube channel.

SAS Training: Just a Click Away

 Ready to level-up your skills? Choose your own adventure.

Browse our catalog!

Discussion stats
  • 3 replies
  • 1657 views
  • 0 likes
  • 3 in conversation