fix: query to get only distinct favPost
This commit is contained in:
parent
669bea7753
commit
7fdc5d15c7
@ -63,7 +63,7 @@ func GetUserFavoritesCount(ctx context.Context, driver neo4j.DriverWithContext,
|
||||
MATCH (userNode:User {user_id: $anthrove_user_id})
|
||||
MATCH (userNode)-[:FAV]->(favPost:AnthrovePost)
|
||||
MATCH (sourceNode)-[:REFERENCE]->(favPost)
|
||||
RETURN count(favPost) AS FavoritePostsCount
|
||||
RETURN count( DISTINCT favPost) AS FavoritePostsCount
|
||||
`
|
||||
|
||||
params := map[string]any{
|
||||
|
Reference in New Issue
Block a user