adding db-traversals - treating the database as graph