-> Sort (cost=275515.84..275515.85 rows=1 width=121) (actual time=117717.71..117717.86 rows=175 loops=1) Sort Key: nation.n_name, date_part('year'::text, orders.o_orderdate) -> Aggregate (cost=275515.79..275515.83 rows=1 width=121) (actual time=112148.50..117695.96 rows=175 loops=1) -> Group (cost=275515.79..275515.82 rows=4 width=121) (actual time=112112.94..115304.49 rows=348760 loops=1) -> Sort (cost=275515.79..275515.80 rows=4 width=121) (actual time=112112.92..112692.28 rows=348760 loops=1) Sort Key: nation.n_name, date_part('year'::text, orders.o_orderdate) -> Hash Join (cost=275514.34..275515.76 rows=4 width=121) (actual time=90951.45..93789.83 rows=348760 loops=1) Hash Cond: ("outer".n_nationkey = "inner".s_nationkey) -> Seq Scan on nation (cost=0.00..1.25 rows=25 width=33) (actual time=4.68..5.06 rows=25 loops=1) -> Hash (cost=275514.33..275514.33 rows=4 width=88) (actual time=90946.56..90946.56 rows=0 loops=1) -> Nested Loop (cost=9316.56..275514.33 rows=4 width=88) (actual time=6291.61..89426.31 rows=348760 loops=1) -> Hash Join (cost=9316.56..275503.33 rows=4 width=76) (actual time=6254.32..70681.20 rows=348760 loops=1) Hash Cond: ("outer".l_partkey = "inner".ps_partkey) Join Filter: ("inner".s_suppkey = "outer".l_suppkey) -> Seq Scan on lineitem (cost=0.00..235620.15 rows=6001215 width=45) (actual time=9.80..43111.28 rows=6001215 loops=1) -> Hash (cost=9313.36..9313.36 rows=1280 width=31) (actual time=6244.16..6244.16 rows=0 loops=1) -> Hash Join (cost=8871.36..9313.36 rows=1280 width=31) (actual time=5967.82..6163.98 rows=46548 loops=1) Hash Cond: ("outer".s_suppkey = "inner".ps_suppkey) -> Seq Scan on supplier (cost=0.00..351.00 rows=10000 width=8) (actual time=0.45..55.78 rows=10000 loops=1) -> Hash (cost=8868.16..8868.16 rows=1280 width=23) (actual time=5967.02..5967.02 rows=0 loops=1) -> Nested Loop (cost=0.00..8868.16 rows=1280 width=23) (actual time=8.14..5856.17 rows=46548 loops=1) -> Seq Scan on part (cost=0.00..7867.00 rows=320 width=4) (actual time=8.07..1554.41 rows=11637 loops=1) Filter: (p_name ~~ '%green%'::text) -> Index Scan using i_ps_partkey on partsupp (cost=0.00..3.07 rows=5 width=19) (actual time=0.31..0.35 rows=4 loops=11637) Index Cond: ("outer".p_partkey = partsupp.ps_partkey) -> Index Scan using pk_orders on orders (cost=0.00..3.01 rows=1 width=12) (actual time=0.04..0.04 rows=1 loops=348760) Index Cond: (orders.o_orderkey = "outer".l_orderkey) Total runtime: 117758.96 msec (29 rows)