From 216c08c623a4d404c63c3aff7c2366800367c764 Mon Sep 17 00:00:00 2001 From: alemi Date: Sat, 8 Jun 2024 04:05:01 +0200 Subject: [PATCH] fix: do i need to group by more? --- upub/core/src/selector.rs | 3 +++ 1 file changed, 3 insertions(+) diff --git a/upub/core/src/selector.rs b/upub/core/src/selector.rs index 5c1680a7..9229c67c 100644 --- a/upub/core/src/selector.rs +++ b/upub/core/src/selector.rs @@ -18,6 +18,8 @@ impl Query { .add(model::object::Column::Id.is_not_null()) ) .group_by(model::activity::Column::Internal) + .group_by(model::object::Column::Internal) + .group_by(model::like::Column::Internal) .order_by(model::addressing::Column::Published, Order::Desc) .select_only(); @@ -47,6 +49,7 @@ impl Query { // .distinct() .join(sea_orm::JoinType::InnerJoin, model::addressing::Relation::Objects.def()) .group_by(model::object::Column::Internal) + .group_by(model::like::Column::Internal) .order_by(model::addressing::Column::Published, Order::Desc) .select_only();