DATA Step, Macro, Functions and more

two datasets

Reply
Super Contributor
Posts: 647

two datasets

0ANUEL
0HRISTOPHE
1009
121
121ST
133NB2
137
1635
19ND72
1COTT


I want to create two datasets separating the above data based on only numbers and mix of numbers and alpha.
like 1009,121,137,1635 go into one dataset and other values into another dataset

Super User
Posts: 10,497

Re: two datasets

Data digits alpha;

     set have;

     if anyalpha(charactervariablename) > 0 then output alpha;

     else output digits;

run;

Ask a Question
Discussion stats
  • 1 reply
  • 142 views
  • 0 likes
  • 2 in conversation