Change init_database to use enumerate
merge