BookmarkSubscribeRSS Feed
CurtisER
Obsidian | Level 7

What does this error code 2000 returned from &SYSERR mean?

2000 Semantic action problem

I have an user who keeps encountering this error on a Linux machine.  When I run this user's code under my account on a Linux machine, it ran fine with return code 0.  However, this user consistently keeps getting return code 2000.  Does it have to something with the user's SAS profile and/or configuration?

 

So, can someone explain what is a "semantic action problem"?

 

Thank you.

7 REPLIES 7
Reeza
Super User

Does the log have other errors? I would guess so and that would be significantly easier to debug. 

 

Sadly, a return code of 0 doesn't mean something ran successfully either. 

 

proc means data=sashelp.class;
var weight;
output out=want mean= / autotest
run;

%put &syserr.;
CurtisER
Obsidian | Level 7

Does the log have other errors? I would guess so and that would be significantly easier to debug. 

 

In the user's log, it shows the error message as:

 

ERROR:

.

 

Which was very cryptic.  Then, I added &SYSERR in two places.  The first one came back as 0 and the second one came back as 2000.

 

It's between ODS PDF FILE= ...., PROC REPORT, and ODS PDF CLOSE;

 

I couldn't replicate this on my own because I don't have an error since it works fine.  I've attached a log for review.

PGStats
Opal | Level 21

Covered on page 12-16 of

 

http://support.sas.com/publishing/pubcat/chaps/57743.pdf

 

 

PG
CurtisER
Obsidian | Level 7

Good reference info -- My search didn't come across this document earlier.  I'll review this.

Reeza
Super User

Since the error is right after this line:

ods pdf file="<deleted>/reports/sa_compare_x11_seats_oct.pdf" notoc;

 

Does the user have access to this location to create a file in that location?

 

 

CurtisER
Obsidian | Level 7

Does the user have access to this location to create a file in that location?

 

Yes, we both do.  The user actually owns the directory.  The <deleted> part is reacted but it is a fully qualified path from root level down to the reports subdirectory.

 

Under my account, I ran the code myself and I didn't have any errors and the PDF was generated.  Under this user's account, the user got this error with code 2000.  If there was truly an error in the code, I would have gotten the same error as the user did but it did not happen.

 

That's why I'm at a loss to explain.

 

Thanks.

Reeza
Super User

I'd probably say, pull it out of the macro/stored process, run each step individually so you can isolate where exactly the error is occurring and go from there. 

CFC_SAS_Communities_400x225.jpg

Call for content now open!

It's your turn to help shape SAS Innovate 2027. Share your expertise and inspire the SAS community.

Submit your proposal →

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.

SAS Training: Just a Click Away

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

Browse our catalog!

Discussion stats
  • 7 replies
  • 6296 views
  • 0 likes
  • 3 in conversation