06-06-2012 10:05 AM
I have been tasked to assign the same numbers (not increments) for duplicate records. Here is an example of what I want to accomplish:
ID Code Number
06-06-2012 10:09 AM
hi ..., if data are sorted by IDCODE ...
ps take a look at ... http://www.sascommunity.org/wiki/Tips:Between_and_Within_Group_Counters
06-06-2012 09:52 PM
I didn't want to write 20+ if-then statements for each letter of the alphabet lol...
In your sample data , there is only one variable idcode .
The same with Mike, Assuming you have sorted dataset by idcode.
if idcode ne lag(idcode) then number+1;