updated db model