Aggregate (cost=308.53..308.54 rows=1 width=8) |
-> Sort (cost=299.38..300.90 rows=610 width=2812) |
Sort Key: (sum(pc.total_amount)) DESC NULLS LAST |
-> HashAggregate (cost=263.53..271.16 rows=610 width=2812) |
Group Key: s.id |
-> Hash Left Join (cost=230.77..260.48 rows=610 width=36) |
Hash Cond: (s.id = pc.supplier_id) |
-> Seq Scan on tbl_suppliers s (cost=0.00..28.10 rows=610 width=4) |
-> Hash (cost=225.53..225.53 rows=419 width=36) |
-> Subquery Scan on pc (cost=216.11..225.53 rows=419 width=36) |
-> HashAggregate (cost=216.11..221.34 rows=419 width=100) |
Group Key: pc_1.supplier_id |
-> Seq Scan on tbl_purchase_contracts pc_1 (cost=0.00..206.07 rows=2007 width=10) |