QUERY PLAN
HashAggregate (cost=337.06..337.38 rows=32 width=4)
Group Key: c.deduct_points_from
-> Hash Join (cost=34.27..336.39 rows=268 width=4)
Hash Cond: (c.id = crd.case_id)
-> Seq Scan on tbl_cases c (cost=0.00..267.41 rows=8541 width=8)
-> Hash (cost=30.92..30.92 rows=268 width=4)
-> Hash Join (cost=8.84..30.92 rows=268 width=4)
Hash Cond: (crr.remind_date_id = crd.id)
-> Seq Scan on tbl_case_remind_receivers crr (cost=0.00..21.36 rows=268 width=4)
Filter: (user_id = 1015)
-> Hash (cost=5.04..5.04 rows=304 width=8)
-> Seq Scan on tbl_case_remind_dates crd (cost=0.00..5.04 rows=304 width=8)