QUERY PLAN
HashAggregate (cost=361.00..361.10 rows=10 width=4)
Group Key: client.sales_rep
-> Hash Left Join (cost=158.83..359.34 rows=664 width=4)
Hash Cond: (p.client_id = client.id)
-> Hash Join (cost=23.54..222.31 rows=664 width=4)
Hash Cond: (p.id = prr.project_id)
-> Seq Scan on tbl_projects p (cost=0.00..176.42 rows=3142 width=8)
-> Hash (cost=15.24..15.24 rows=664 width=4)
-> Seq Scan on tbl_project_remind_receivers prr (cost=0.00..15.24 rows=664 width=4)
Filter: (user_id = 1001)
-> Hash (cost=110.13..110.13 rows=2013 width=8)
-> Seq Scan on tbl_clients client (cost=0.00..110.13 rows=2013 width=8)