|
I think that this is a solution:
/***************************************
INPUT.TXT CONTAINS:
THIS^^IS^^A^^TEST
TO^^SEE^^WHAT^^HAPPENS^^FOR^^THIS^^^^FILE
***************************************/
libname lib 'd:\test\dlm_tst\';
FILENAME MYINPUT 'D:\TEST\DLM_TST\INPUT.TXT';
data newds;
length my_word $ 15;
INFILE MYINPUT delimiter='^^';
input my_word @@;
RUN;
/*******************************************
NEWDS CONTAINS THE FOLLOWING 11 RECORDS:
THIS
IS
A
TEST
TO
SEE
WHAT
HAPPENS
FOR
THIS
FILE
******************************************/
timpi@FMRCO.COM on 04/15/98 02:19:12 PM
Please respond to timpi@FMRCO.COM
To: SAS-L@UGA.CC.UGA.EDU
cc: (bcc: Victoria M Wilkins/Ingenium/US)
Subject: help read a record and then output ...
Hi SAS users,
I have a file in the following format :
^^xxxx^^jljlsas^^n134vzcsdr^^re3nh4^^ ...............^^
The ^^ is the delimiter. I want to convert it into multiple records
like
xxxx
jljlsas
n134vzcsdr
....
However the number of ^^ is different everytime I get the file.
Any idea?
Thx!
Tim Pi
|