05-22-2015 04:50 PM
batch replacing of what? Values in a data set? Code files? External files?
And which file format/ operating system. Unix and Windows use different characters to denote end of line/ end of record.
Do you need to enter a value in program code? Do you need to identify something that your files are using other than operating system standard characters?
05-23-2015 04:13 PM
My answers from my work email did not show here.
So I copied them here.
Just edit a text file as in general editor. Editor has replace
feature and I need to specify what to replace what.
To do this I need to know what char stands for ‘end of
record’/’beginning of record’ in the replace dialog.
Code file as a text file. I am under windows.
05-23-2015 01:29 PM
The Windows/Unix environment is using a CR-LF LF CR (one of those) indicating the end of a record. This is very basic inherited from 7-bit ascii telex tty age.
This is how all tools and program editor are working. Often there is limit in the length of processing (no character) as with limited memory and processor-register usage.
A counter of 1 byte is ending at 255 length. This is a common limit for code with Unix (and SAS editor) with two-bytes and a sign this upper limit is 32K. That size can be set with sas as them maximum length. (default with 9.4 I believe).
The exception is Mainframes FB VB are not using chars for the end of record but they are system defined. They still often use a 80 max (Hollerith) source line. With a VBS you could use a 32k length. Only with downloading datasets from mainframe to Unix/Windows you have that kind of issues to take care of. SAS is supporting those mainframe approaches on Windows/Unix as it has his origins there. Not all tools are having that.
05-23-2015 04:33 PM
I no can get it clearly.
I use Widows. I knew Unix, VAX/VMS too. Have not heard FB VB yet.
on SAS online documentation there is one about INFILE OPTIONS:
CRLF for windows formatted file;
LF, NL for Unix
This is quite related to my question.
But it is related to reading files to a SAS dataset..
Combine all those I have said:
What keys I should type for beginning/ending in the Replace dialog box under SAS extended editor???
05-24-2015 01:29 AM
The include is an external file there are many options for that like the infile and some special for source/code behavior .
SAS(R) 9.4 Companion for Windows, Third Edition and linesize log/output windows - 256
SAS(R) 9.4 System Options: Reference, Third Edition source2 display included code in log
SAS(R) 9.4 System Options: Reference, Third Edition s2= limiting input source lines
SAS(R) 9.4 System Options: Reference, Third Edition lrecl= the default length for reading external files, zee the note on F than it is 256
SAS(R) 9.4 System Options: Reference, Third Edition cardimage that mainframe history
These are the documented settings that can cause cutting the length. In previous versions you are more often hit by some old convention as that 255
Thos cr/lf are hardly replacable as they are are global conventions being used everywhere.
When you have a problem with Excel csv having new-lines within cells there is some trick I believe. That is when the hard return is a CR and the new line a CR-LF you can diffentiate between those
Another would be fixing the record convention before processing.