Hello,
In one of my table, I was able to pick all the code that are used in our programs which may vary between 0 and 9 and between
a and z.
For example if my codelist = 1 2 3 4 x y z then I would like to find a way to obtains the one that are not in our codelist such as
0 5 6 7 8 9 a b c d e f g h i j k l m n o p q r s t u v w. How to do that?
Regards,
Please explain more about how you have the current data.
If you have strings you might try the COMPRESS() function.
601 data test;
602 length all some rest $36 ;
603 all = collate(rank('0'),rank('9'))||collate(rank('a'),rank('z'));
604 some='345bcdegh';
605 rest=compress(all,some);
606 put (_all_) (=/);
607 run;
all=0123456789abcdefghijklmnopqrstuvwxyz
some=345bcdegh
rest=0126789afijklmnopqrstuvwxyz
Please explain more about how you have the current data.
If you have strings you might try the COMPRESS() function.
601 data test;
602 length all some rest $36 ;
603 all = collate(rank('0'),rank('9'))||collate(rank('a'),rank('z'));
604 some='345bcdegh';
605 rest=compress(all,some);
606 put (_all_) (=/);
607 run;
all=0123456789abcdefghijklmnopqrstuvwxyz
some=345bcdegh
rest=0126789afijklmnopqrstuvwxyz
Good news: We've extended SAS Hackathon registration until Sept. 12, so you still have time to be part of our biggest event yet – our five-year anniversary!
Check out this tutorial series to learn how to build your own steps in SAS Studio.
Find more tutorials on the SAS Users YouTube channel.
Ready to level-up your skills? Choose your own adventure.