if i have two columns
001, apple
001, orange
001, orange
001, fish
001, fish
001, fish
002, apple
002, meat
002, meat
003, beef

how can i get the following result
001, apple, 1
001, orange, 2
001, fish, 3
002, apple, 1
002, meat, 2
003, beef, 1