How can I insert a consecutive number in each entry?