Added database updation functionality