LISTSERV at the University of Georgia
Menubar Imagemap
Home Browse Manage Request Manuals Register
Previous messageNext messagePrevious in topicNext in topicPrevious by same authorNext by same authorPrevious page (February 2010, week 1)Back to main SAS-L pageJoin or leave SAS-L (or change settings)ReplyPost a new messageSearchProportional fontNon-proportional font
Date:         Mon, 1 Feb 2010 08:48:53 -0800
Reply-To:     "Terjeson, Mark" <Mterjeson@RUSSELL.COM>
Sender:       "SAS(r) Discussion" <SAS-L@LISTSERV.UGA.EDU>
From:         "Terjeson, Mark" <Mterjeson@RUSSELL.COM>
Subject:      Re: Problem running bat file
In-Reply-To:  A<201002011635.o11Bn0gs013962@malibu.cc.uga.edu>
Content-Type: text/plain; charset="us-ascii"

Hi Sunny,

In addition to Ya's observation to tell the .bat file to treat the lines as continuation lines so that it looks like one command line to the operating system, bear in mind that on Windows, if you were to concatenate all the pieces onto one line, that the DOS command line has a max character limit of 251 to 262.

Typically with DOS command line lengths the maximum is around 262. Depending upon how many layers through the operating system, scheduling utilities, number of shells, etc. the number can vary slightly. Trial and error testing lets a person know the max for each scenario. The miminum maximum that I have come across for 4 layers of expression handling in a DOS/Windows/network environment is 251. i.e. some command parsers in the DOS/Windows/network world actually gobble up the CRLF pair and your available length is -2 just because of that. (Go figure...)

One of the easiest and straightforward workarounds is to shorten path and file names IF you have that luxury, and if it becomes desideratum.

Hope this is helpful.

Mark Terjeson Investment Business Intelligence Investment Management & Research Russell Investments 253-439-2367

Russell Global Leaders in Multi-Manager Investing

-----Original Message----- From: SAS(r) Discussion [mailto:SAS-L@LISTSERV.UGA.EDU] On Behalf Of Ya Huang Sent: Monday, February 01, 2010 8:35 AM To: SAS-L@LISTSERV.UGA.EDU Subject: Re: Problem running bat file

Looks like you broke the long line into several command lines, if so, yoou need the '^' to connect them:

"C:\program files\sas\sasfoundation\9.2\sas.exe" ^ -CONFIG "C:\Program Files\SAS\SASFoundation\9.2\nls\en\SASV9.CFG" ^ -sysin C:\users\runit\prog1.sas

Otherwise, DOS will think there are three command lines.

On Mon, 1 Feb 2010 08:12:40 -0800, Sunny <msunny17@GMAIL.COM> wrote:

>Hello Group, > > I've a problem while running a .bat file I got the >bunch of errors. > When it open SAS it gives some warning and error >message in DOS cmd prompt. > > >-CONFIG is not recognized as internal or external command, operable >program or batch file > >-sysin is not recognized as internal or external command, operable >program or batch file. > > >Here is my .bat File > > >Run.Bat File > >"C:\program files\sas\sasfoundation\9.2\sas.exe" > >-CONFIG "C:\Program Files\SAS\SASFoundation\9.2\nls\en\SASV9.CFG" > > -sysin > >C:\users\runit\prog1.sas > >When it open SAS it gives this message > >NOTE: Unable to open SASUSER.REGSTRY. WORK.REGSTRY will be opened >instead. >NOTE: All registry changes will be lost at the end of the session. >WARNING: Unable to copy SASUSER registry to WORK registry. Because of >this, >WARNING: you will not see registry customizations during this session. >NOTE: Unable to open SASUSER.PROFILE. WORK.PROFILE will be opened >instead. >NOTE: All profile changes will be lost at the end of the session. >NOTE: This SAS session is using a registry in WORK. All changes will >be lost at the end of this >NOTE: session. >NOTE: Unable to open SASUSER.PROFILE. WORK.PROFILE will be opened >instead. >NOTE: All profile changes will be lost at the end of the session. > > Will appreciate your help. > >Thanks > >Sunny


Back to: Top of message | Previous page | Main SAS-L page