add selfJoin option - Juan