QUERY PLAN
HashAggregate (cost=414.73..414.81 rows=8 width=4)
Group Key: client.sales_rep
-> Hash Left Join (cost=221.86..413.30 rows=572 width=4)
Hash Cond: (p.client_id = client.id)
-> Hash Join (cost=19.41..209.35 rows=572 width=4)
Hash Cond: (p.id = prr.project_id)
-> Seq Scan on tbl_projects p (cost=0.00..169.48 rows=2948 width=8)
-> Hash (cost=12.26..12.26 rows=572 width=4)
-> Seq Scan on tbl_project_remind_receivers prr (cost=0.00..12.26 rows=572 width=4)
Filter: (user_id = 1001)
-> Hash (cost=178.31..178.31 rows=1931 width=8)
-> Seq Scan on tbl_clients client (cost=0.00..178.31 rows=1931 width=8)