Adding function: update/delete, updated other functions