Count Relationships per Row?

If I have not misunderstood,
it would be enough to add the User node to the return of your query.
So:

MATCH (u:User)-[mRel:IS_MEMBER]->(hh:Household) return COUNT(DISTINCT mRel) as count, u

in this way you group count per User node,
so you could do for example:

MATCH (u:User)-[mRel:IS_MEMBER]->(hh:Household) WITH COUNT(DISTINCT mRel) as count, u
RETURN case count when 1 then "first thing" else "second thing" end as result
1 Like