2 --------------------------------------------------------------------------------------------------------------------
3 Aggregate (cost=xxx rows=1 width=4)
4 InitPlan 1 (returns $1)
5 -> Aggregate (cost=xxx rows=1 width=4)
6 -> Nested Loop (cost=xxx rows=100 width=4)
7 Join Filter: (b1t2.c1 = b1t1.c1)
8 -> Hash Join (cost=xxx rows=100 width=12)
9 Hash Cond: (b1t4.c1 = b1t2.c1)
10 -> Seq Scan on t4 b1t4 (cost=xxx rows=1100 width=4)
11 -> Hash (cost=xxx rows=100 width=8)
12 -> Merge Join (cost=xxx rows=100 width=8)
13 Merge Cond: (b1t3.c1 = b1t2.c1)
14 -> Index Only Scan using t3_i1 on t3 b1t3 (cost=xxx rows=1100 width=4)
15 -> Sort (cost=xxx rows=100 width=4)
17 -> Seq Scan on t2 b1t2 (cost=xxx rows=100 width=4)
18 -> Index Only Scan using t1_i1 on t1 b1t1 (cost=xxx rows=1 width=4)
19 Index Cond: (c1 = b1t3.c1)
20 InitPlan 2 (returns $3)
21 -> Aggregate (cost=xxx rows=1 width=4)
22 -> Nested Loop (cost=xxx rows=100 width=4)
23 -> Hash Join (cost=xxx rows=1000 width=12)
24 Hash Cond: (b2t3.c1 = b2t1.c1)
25 -> Merge Join (cost=xxx rows=1100 width=8)
26 Merge Cond: (b2t3.c1 = b2t4.c1)
27 -> Index Only Scan using t3_i1 on t3 b2t3 (cost=xxx rows=1100 width=4)
28 -> Index Only Scan using t4_i1 on t4 b2t4 (cost=xxx rows=1100 width=4)
29 -> Hash (cost=xxx rows=1000 width=4)
30 -> Seq Scan on t1 b2t1 (cost=xxx rows=1000 width=4)
31 -> Index Only Scan using t2_i1 on t2 b2t2 (cost=xxx rows=1 width=4)
32 Index Cond: (c1 = b2t1.c1)
33 InitPlan 3 (returns $5)
34 -> Aggregate (cost=xxx rows=1 width=4)
35 -> Nested Loop (cost=xxx rows=100 width=4)
36 Join Filter: (b3t1.c1 = b3t3.c1)
37 -> Hash Join (cost=xxx rows=100 width=12)
38 Hash Cond: (b3t1.c1 = b3t2.c1)
39 -> Merge Join (cost=xxx rows=1000 width=8)
40 Merge Cond: (b3t1.c1 = b3t4.c1)
41 -> Index Only Scan using t1_i1 on t1 b3t1 (cost=xxx rows=1000 width=4)
42 -> Index Only Scan using t4_i1 on t4 b3t4 (cost=xxx rows=1100 width=4)
43 -> Hash (cost=xxx rows=100 width=4)
44 -> Seq Scan on t2 b3t2 (cost=xxx rows=100 width=4)
45 -> Index Only Scan using t3_i1 on t3 b3t3 (cost=xxx rows=1 width=4)
46 Index Cond: (c1 = b3t4.c1)
47 -> Nested Loop (cost=xxx rows=100 width=4)
48 Join Filter: (bmt1.c1 = bmt4.c1)
49 -> Hash Join (cost=xxx rows=100 width=12)
50 Hash Cond: (bmt3.c1 = bmt1.c1)
51 -> Seq Scan on t3 bmt3 (cost=xxx rows=1100 width=4)
52 -> Hash (cost=xxx rows=100 width=8)
53 -> Merge Join (cost=xxx rows=100 width=8)
54 Merge Cond: (bmt1.c1 = bmt2.c1)
55 -> Index Only Scan using t1_i1 on t1 bmt1 (cost=xxx rows=1000 width=4)
56 -> Sort (cost=xxx rows=100 width=4)
58 -> Seq Scan on t2 bmt2 (cost=xxx rows=100 width=4)
59 -> Index Only Scan using t4_i1 on t4 bmt4 (cost=xxx rows=1 width=4)
60 Index Cond: (c1 = bmt3.c1)
64 --------------------------------------------------------------------------------------------------------------------
65 Aggregate (cost=xxx rows=1 width=4)
66 InitPlan 1 (returns $1)
67 -> Aggregate (cost=xxx rows=1 width=4)
68 -> Nested Loop (cost=xxx rows=1 width=4)
69 Join Filter: (b1t2.c1 = b1t1.c1)
70 -> Hash Join (cost=xxx rows=1 width=12)
71 Hash Cond: (b1t4.c1 = b1t2.c1)
72 -> Seq Scan on t4 b1t4 (cost=xxx rows=1100 width=4)
73 -> Hash (cost=xxx rows=1 width=8)
74 -> Merge Join (cost=xxx rows=1 width=8)
75 Merge Cond: (b1t3.c1 = b1t2.c1)
76 -> Index Only Scan using t3_i1 on t3 b1t3 (cost=xxx rows=1100 width=4)
77 -> Sort (cost=xxx rows=100 width=4)
79 -> Seq Scan on t2 b1t2 (cost=xxx rows=100 width=4)
80 -> Index Only Scan using t1_i1 on t1 b1t1 (cost=xxx rows=1 width=4)
81 Index Cond: (c1 = b1t3.c1)
82 InitPlan 2 (returns $3)
83 -> Aggregate (cost=xxx rows=1 width=4)
84 -> Nested Loop (cost=xxx rows=1 width=4)
85 -> Hash Join (cost=xxx rows=1 width=12)
86 Hash Cond: (b2t1.c1 = b2t3.c1)
87 -> Seq Scan on t1 b2t1 (cost=xxx rows=1000 width=4)
88 -> Hash (cost=xxx rows=1 width=8)
89 -> Merge Join (cost=xxx rows=1 width=8)
90 Merge Cond: (b2t3.c1 = b2t4.c1)
91 -> Index Only Scan using t3_i1 on t3 b2t3 (cost=xxx rows=1100 width=4)
92 -> Index Only Scan using t4_i1 on t4 b2t4 (cost=xxx rows=1100 width=4)
93 -> Index Only Scan using t2_i1 on t2 b2t2 (cost=xxx rows=1 width=4)
94 Index Cond: (c1 = b2t1.c1)
95 InitPlan 3 (returns $5)
96 -> Aggregate (cost=xxx rows=1 width=4)
97 -> Nested Loop (cost=xxx rows=1 width=4)
98 Join Filter: (b3t1.c1 = b3t3.c1)
99 -> Hash Join (cost=xxx rows=1 width=12)
100 Hash Cond: (b3t1.c1 = b3t2.c1)
101 -> Merge Join (cost=xxx rows=1 width=8)
102 Merge Cond: (b3t1.c1 = b3t4.c1)
103 -> Index Only Scan using t1_i1 on t1 b3t1 (cost=xxx rows=1000 width=4)
104 -> Index Only Scan using t4_i1 on t4 b3t4 (cost=xxx rows=1100 width=4)
105 -> Hash (cost=xxx rows=100 width=4)
106 -> Seq Scan on t2 b3t2 (cost=xxx rows=100 width=4)
107 -> Index Only Scan using t3_i1 on t3 b3t3 (cost=xxx rows=1 width=4)
108 Index Cond: (c1 = b3t4.c1)
109 -> Nested Loop (cost=xxx rows=1 width=4)
110 Join Filter: (bmt1.c1 = bmt4.c1)
111 -> Hash Join (cost=xxx rows=1 width=12)
112 Hash Cond: (bmt3.c1 = bmt1.c1)
113 -> Seq Scan on t3 bmt3 (cost=xxx rows=1100 width=4)
114 -> Hash (cost=xxx rows=1 width=8)
115 -> Merge Join (cost=xxx rows=1 width=8)
116 Merge Cond: (bmt1.c1 = bmt2.c1)
117 -> Index Only Scan using t1_i1 on t1 bmt1 (cost=xxx rows=1000 width=4)
118 -> Sort (cost=xxx rows=100 width=4)
120 -> Seq Scan on t2 bmt2 (cost=xxx rows=100 width=4)
121 -> Index Only Scan using t4_i1 on t4 bmt4 (cost=xxx rows=1 width=4)
122 Index Cond: (c1 = bmt3.c1)