Why? All of the possible numeric suffixes in those ranges will include codes that are not valid HCPCS codes.
Just merge the list with a list of valid codes and pick the ones that fall between the two codes.
Let's assume the table you are showing is named HAVE and last two variables are named LOW and HIGH. So if your dictionary table of all valid codes is named HCPCS then just join them:
proc sql;
create table want as
select a.*,b.code
from have a
left join hcpcs b
on b.code between a.low and a.high
;
quit;
... View more