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 (August 2008, week 3)Back to main SAS-L pageJoin or leave SAS-L (or change settings)ReplyPost a new messageSearchProportional fontNon-proportional font
Date:         Thu, 21 Aug 2008 00:14:58 GMT
Reply-To:     Lou <lpogoda@VERIZON.NET>
Sender:       "SAS(r) Discussion" <SAS-L@LISTSERV.UGA.EDU>
From:         Lou <lpogoda@VERIZON.NET>
Subject:      Re: Difference between Batch and Interactive runs
Comments: To:

"FPAStatman" <> wrote in message > I have a program that I have run through interactive or window mode in > SAS, and it runs just fine. I then run the exact same program with > the exact same data through batch mode, and it freezes. Does anyone > know why this would be? > Every time when I've seen this kind of situation, it's because the program was written interactively using the "enhanced" editor, and the programmer didn't pay attention.

The enhanced editor lets you write code with long lines - I don't know what the limit is, or even if there is one.

However, when a program is run in batch, SAS has to make some assumptions about the program file. One of these assumptions is the length of the lines in order to set up an input buffer. If a line is longer than the buffer allows, it gets truncated, and depending on what's going on at the point of truncation, the thing can just sit there. For instance, if a comment is opened with a /* and the comment closing */ gets truncated, as far as SAS is concerned the rest of the file is all part of the comment and the process just sits there. Just as it would in interactive mode if you submitted the comment opening /* and never closed the comment.

I've seen many a programmer write stuff that will only run when submitted from the enhanced editor, and the reason has always been that some program line(s) exceeded the maximum length accepted by the batch process. Pretty poor practice, in my opinion, both on the part of the programmer for writing in such a run on fashion, and on the part of SAS for introducing yet another internal inconsistency.

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