update note and db