f



Re: Help needed to convert text file to SAS file #2

My 2p:

data i;
retain name_part value_part;
infile 'c:\temp\sas.txt' dlm = "|}|" /*JUNK DELIMETER.*/ dsd missover lrecl
= 440;
informat text $440. value_part $422. name_part $28.;
input text;
if 2 < _N_ < 9 then delete;
if text ^ = "";
if text =:"Notes: Spoke with" then text =
tranwrd(text,"re:Patient","re.Patient");
name_part = trim(left(scan(text,1,':')));
value_part = trim(left(scan(text,2,':')));
if text=:"Notes: Spoke" then value_part = trim(left(value_part)) || " " ||
"thx";
if text = "thx" then delete;
drop text;
run;
0
ben.powell1 (971)
7/26/2005 11:23:34 AM
comp.soft-sys.sas 142828 articles. 3 followers. Post Follow

0 Replies
721 Views

Similar Articles

[PageSpeed] 34

Reply: