groupby-fix
This commit is contained in:
parent
54eeb5b549
commit
b13d57ca17
|
@ -54,9 +54,7 @@ def add_topic_stat_columns(q):
|
|||
func.coalesce(func.sum(sub_comments.c.comments_count), 0).label('comments_stat')
|
||||
)
|
||||
|
||||
q = q.group_by(
|
||||
Topic.id, 'shouts_stat', 'authors_stat', 'followers_stat', 'comments_stat'
|
||||
)
|
||||
q = q.group_by(Topic.id, sub_comments.c.comments_stat)
|
||||
|
||||
return q
|
||||
|
||||
|
|
Loading…
Reference in New Issue
Block a user