saving annotations to Database
refactoring