Read/Write to db.