2 -----------------------------------------------------------------------------------------------
3 Aggregate (cost=xxx rows=1 width=4)
4 -> Merge Join (cost=xxx rows=100 width=4)
5 Merge Cond: (bmt1.c1 = bmt2.c1)
6 -> Index Only Scan using t1_i1 on t1 bmt1 (cost=xxx rows=1000 width=4)
7 -> Sort (cost=xxx rows=100 width=12)
9 -> Hash Join (cost=xxx rows=100 width=12)
10 Hash Cond: (bmt3.c1 = bmt2.c1)
11 -> Hash Join (cost=xxx rows=1100 width=8)
12 Hash Cond: (bmt3.c1 = bmt4.c1)
13 -> Seq Scan on t3 bmt3 (cost=xxx rows=1100 width=4)
14 -> Hash (cost=xxx rows=1100 width=4)
15 -> Seq Scan on t4 bmt4 (cost=xxx rows=1100 width=4)
16 -> Hash (cost=xxx rows=100 width=4)
17 -> Seq Scan on t2 bmt2 (cost=xxx rows=100 width=4)
21 --------------------------------------------------------------------------------------------
22 Aggregate (cost=xxx rows=1 width=4)
23 -> Nested Loop (cost=xxx rows=1 width=4)
24 Join Filter: (bmt2.c1 = bmt1.c1)
25 -> Nested Loop (cost=xxx rows=1 width=12)
26 -> Hash Join (cost=xxx rows=1 width=8)
27 Hash Cond: (bmt3.c1 = bmt4.c1)
28 -> Seq Scan on t3 bmt3 (cost=xxx rows=1100 width=4)
29 -> Hash (cost=xxx rows=1100 width=4)
30 -> Seq Scan on t4 bmt4 (cost=xxx rows=1100 width=4)
31 -> Index Only Scan using t2_i1 on t2 bmt2 (cost=xxx rows=1 width=4)
32 Index Cond: (c1 = bmt3.c1)
33 -> Index Only Scan using t1_i1 on t1 bmt1 (cost=xxx rows=1 width=4)
34 Index Cond: (c1 = bmt3.c1)