Implemented auto-increment for the primary keys