dependency checking for db_write