- Mark as New
- Bookmark
- Subscribe
- Mute
- RSS Feed
- Permalink
- Report Inappropriate Content
help:
sas editor
Problem Description:
sas editor has
characters for end of record /beginning of record????
I need them to do batch replacing in replacing.
- Mark as New
- Bookmark
- Subscribe
- Mute
- RSS Feed
- Permalink
- Report Inappropriate Content
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?
- Mark as New
- Bookmark
- Subscribe
- Mute
- RSS Feed
- Permalink
- Report Inappropriate Content
My answers from my work email did not show here.
So I copied them here.
-bai
======
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.
-bai
- Mark as New
- Bookmark
- Subscribe
- Mute
- RSS Feed
- Permalink
- Report Inappropriate Content
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.
- Mark as New
- Bookmark
- Subscribe
- Mute
- RSS Feed
- Permalink
- Report Inappropriate Content
Mr Karman:
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:
TERMSTR
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???
Thanks,
-Bai
- Mark as New
- Bookmark
- Subscribe
- Mute
- RSS Feed
- Permalink
- Report Inappropriate Content
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.
- Mark as New
- Bookmark
- Subscribe
- Mute
- RSS Feed
- Permalink
- Report Inappropriate Content
According to SAS tech help: this is impossible.
-bai