Sorry. The criteria I needed was an specific number with two digits (49), and what I really needed is to know whether there is any of the expected number in any of a set of variables. I just finded out that I can do this with an array, works really good as long as each variable in the array has the same format (in my case, numeric). This is an example: data want; set have; array test{*}p_5_1--p_5_10; do i=1 to dim(test); if test(i)= 1 then ind1 = 1; else if test(i)= 2 then Ind2 = 1; else if test(i)= 3 then Ind3 = 1; etc... else if test(i)= 68 then Ind68 = 1; end; drop i; run; these are things you find yourself doing when someone has become reaaaally original when generating a data base... I´m trying to stay positive about this...
... View more