BookmarkSubscribeRSS Feed
steve_citi
Calcite | Level 5
I am executing "systask command ...." within a command line macro. However, I am being told the command is not recognized, even though it can be used anywhere.
5 REPLIES 5
SAS_user
Calcite | Level 5
What is that command you are executing?
OS: Windows, Unix?
It's better, to know more info about your problem.
deleted_user
Not applicable
What do you mean by a command line macro?
You may be running into quoting issues?
Are you running batch? or inside an interactive SAS session?
Share some code, it'll be easier to troubleshoot.
rocky1983
Fluorite | Level 6

hi

i am trying to run following code:

SYSTASK COMMAND "MKDIR E:\trial\trial" nowait taskname= "trial" ;

but every time i run i get a error msg in log that:

SYSTASK COMMAND "MKDIR E:\trial\trial" nowait taskname= "trial" ;

                                                                                         -

ERROR 75-169: Equal sign expected.

i did not understand y i am getting this problem. this is kind of straight forward code. any 1 please help me out. i am using windows and sas version 9

Tom
Super User Tom
Super User

SYSTASK cannot run in a command line function.  You can submit it using the GSUB command.

gsub "systask command ""echo hello"" nowait taskname=""trial""; "

rocky1983
Fluorite | Level 6

I have used systask command quite often : I used windows based server and following are sample of code we used:

SYSTASK COMMAND "(location of sas exe file) -noterminal -logparm 'rollover=session' -sysin 'sas code'

  -SYSPARM 'parameter to be passed' -log 'log location'" TASKNAME=taskname

However I do face certains issues sometimes. like code works fine  but during certain time period  code fails to get executed and when I check log we have error that could not create new process.

I checked with SAS reagarding same and they suggested that when system resources(memory) is low we be getting it issue.

sas-innovate-2024.png

Join us for SAS Innovate April 16-19 at the Aria in Las Vegas. Bring the team and save big with our group pricing for a limited time only.

Pre-conference courses and tutorials are filling up fast and are always a sellout. Register today to reserve your seat.

 

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
  • 2487 views
  • 1 like
  • 5 in conversation