Here is an alternative way.
options compress=yes;
data have;
infile cards length=len;
input temp $varying2000. len;
if prxmatch('/^\d+\|\d+/',temp) then group+1;
cards;
1009|234|long description in comments
and need to be updated in the sas dataset.
Thank you for uploading data|264,00|345,09|address
1010|235|long description in comments
and need to be updated in the sas dataset|546.08|589|address
;
data temp;
length x $ 8000;
do until(last.group);
set have;
by group;
x=cats(x,temp);
end;
drop temp;
run;
data want;
set temp;
a1=scan(x,1,'|');
a2=scan(x,2,'|');
a3=scan(x,3,'|');
a4=scan(x,4,'|');
a5=scan(x,5,'|');
a6=scan(x,6,'|');
drop x;
run;
... View more