data test;
infile cards truncover;
input (Bacode1-Bacode3) (: $40.);
cards;
atmbarcode:"FE235. atmbarcode:"Yu23
Atmbarcode:TU35. Row#% atmbarcode:WE45
;
run;
data have;
set test;
length x $ 32767;
x=catx(' ',of Bacode1-Bacode3);
n+1;
pid=prxparse('/atmbarcode:\W*\w+/i');
s=1;
e=length(x);
call prxnext(pid,s,e,x,p,l);
do while(p>0);
Bacode=substr(x,p,l);
output;
call prxnext(pid,s,e,x,p,l);
end;
keep n x Bacode ;
proc transpose data=have out=want(drop=_name_) prefix=Bacode;
by n x;
var Bacode;
run;
Your Error Log information ?
Post a TEXT/CSV file contains your TEST data.
Run PROC CONTENTS DATA=TEST;RUN; and post the result.
April 27 – 30 | Gaylord Texan | Grapevine, Texas
Walk in ready to learn. Walk out ready to deliver. This is the data and AI conference you can't afford to miss.
Register now and save with the early bird rate—just $795!
Learn the difference between classical and Bayesian statistical approaches and see a few PROC examples to perform Bayesian analysis in this video.
Find more tutorials on the SAS Users YouTube channel.
Ready to level-up your skills? Choose your own adventure.