Update DB with references