Your SAS programs, embedded in web apps and elsewhere

Unable to call a SAS Code through Batch command

Accepted Solution Solved
Reply
Occasional Contributor
Posts: 9
Accepted Solution

Unable to call a SAS Code through Batch command

Hi,

 

I have already seen the following post on the SAS communities regarding this issue and othes as well, but none of the solutions are working for me:

https://communities.sas.com/t5/SAS-Stored-Processes/Batch-Process-Throwing-Error/m-p/188757/highligh...

 

This is the code which I am using:

"C:\Program Files\SAS93\x86\SASFoundation\9.3\sas.exe" –sysin   "C:\Users\pullarkd\Documents\Work\SAS Models\Models 1.5\SAS_Models_Macros.sas" -nosplash -icon

 

And this is the error I am getting -

Capture.PNG

 

Would be helpful if some can tell me where I am going wrong.

 

I am sure that the SAS code is accurate, since it runs and when I right click the code and select "Batch Submit", it works.

 

Thanks,

Deepthi


Accepted Solutions
Solution
‎03-17-2016 08:10 AM
PROC Star
Posts: 1,167

Re: Unable to call a SAS Code through Batch command

Posted in reply to dpullarkat

And as one more follow-up to the previous two, I've seen a LOT of problems from any code associated with SAS that has been edited in MS-Word. Word tends to use "pretty" punctuation symbols, which SAS doesn't recognize. In addition to the dashes, watch out for single and double quotes.

 

Tom

View solution in original post


All Replies
Trusted Advisor
Posts: 1,314

Re: Unable to call a SAS Code through Batch command

Posted in reply to dpullarkat

Hi,

 

just a wild guess, but I can see a different "minus sign"on the sysin and the nosplash and icon parameters, which I could see many times on copy and paste from windows.

 

If you run this from the command line, try to type it by hand, replacing the "-" signs by your keyboard's "-" sign.

Occasional Contributor
Posts: 9

Re: Unable to call a SAS Code through Batch command

Posted in reply to JuanS_OCS

Juan and Timmy,

 

Thanks for your suggestions, but it wasn't the hyphen or dash. Instead it was the quotes. I ended up replacing the double quotes with single quotes.

 

Thanks again!

Regular Contributor
Posts: 172

Re: Unable to call a SAS Code through Batch command

Posted in reply to dpullarkat
I'm not as familiar with Windows installations, and maybe this is just a typo in the post, but is there a reason you're using the M-dash (long dash/hyphen) instead of the n-dash (single/short dash/hyphen) for the SYSIN option?
Solution
‎03-17-2016 08:10 AM
PROC Star
Posts: 1,167

Re: Unable to call a SAS Code through Batch command

Posted in reply to dpullarkat

And as one more follow-up to the previous two, I've seen a LOT of problems from any code associated with SAS that has been edited in MS-Word. Word tends to use "pretty" punctuation symbols, which SAS doesn't recognize. In addition to the dashes, watch out for single and double quotes.

 

Tom

☑ This topic is solved.

Need further help from the community? Please ask a new question.

Discussion stats
  • 4 replies
  • 333 views
  • 5 likes
  • 4 in conversation