explain.depesz.com

PostgreSQL's explain analyze made readable

Result: bKS1

Settings
# exclusive inclusive rows x rows loops node
1. 1.402 59.107 ↑ 1.4 103 1

Nested Loop (cost=888.07..15,053.69 rows=140 width=58) (actual time=7.251..59.107 rows=103 loops=1)

2. 1.562 33.639 ↓ 5.0 1,146 1

Nested Loop (cost=887.79..2,464.09 rows=229 width=44) (actual time=7.210..33.639 rows=1,146 loops=1)

3. 1.928 11.449 ↓ 2.4 1,146 1

Hash Join (cost=887.50..1,620.23 rows=476 width=24) (actual time=7.171..11.449 rows=1,146 loops=1)

  • Hash Cond: (ct2.customers_id = ct.customers_id)
4. 2.510 3.345 ↓ 1.0 2,575 1

Bitmap Heap Scan on kk_customers_to_tag ct2 (cost=92.28..811.32 rows=2,563 width=20) (actual time=0.982..3.345 rows=2,575 loops=1)

  • Recheck Cond: ((name)::text = 'PATRIS_KUNDEN_VERTRAGSNUMMER_LEIPZIGMOVE'::text)
  • Heap Blocks: exact=552
5. 0.835 0.835 ↓ 1.0 2,575 1

Bitmap Index Scan on idx_name_kk_customers_to_tag (cost=0.00..91.64 rows=2,563 width=0) (actual time=0.835..0.835 rows=2,575 loops=1)

  • Index Cond: ((name)::text = 'PATRIS_KUNDEN_VERTRAGSNUMMER_LEIPZIGMOVE'::text)
6. 0.361 6.176 ↓ 1.1 1,151 1

Hash (cost=782.16..782.16 rows=1,045 width=4) (actual time=6.176..6.176 rows=1,151 loops=1)

  • Buckets: 2,048 Batches: 1 Memory Usage: 57kB
7. 1.038 5.815 ↓ 1.1 1,151 1

HashAggregate (cost=771.71..782.16 rows=1,045 width=4) (actual time=5.457..5.815 rows=1,151 loops=1)

  • Group Key: ct.customers_id
8. 4.329 4.777 ↓ 1.0 1,151 1

Bitmap Heap Scan on kk_customers_to_tag ct (cost=41.09..768.91 rows=1,119 width=4) (actual time=0.534..4.777 rows=1,151 loops=1)

  • Recheck Cond: ((name)::text = 'DRIVER_LICENSE_NUMBER'::text)
  • Heap Blocks: exact=457
9. 0.448 0.448 ↓ 1.0 1,151 1

Bitmap Index Scan on idx_name_kk_customers_to_tag (cost=0.00..40.81 rows=1,119 width=0) (actual time=0.448..0.448 rows=1,151 loops=1)

  • Index Cond: ((name)::text = 'DRIVER_LICENSE_NUMBER'::text)
10. 20.628 20.628 ↑ 1.0 1 1,146

Index Scan using idxkk_customers_to_tag_customers_id on kk_customers_to_tag ct1 (cost=0.29..1.76 rows=1 width=20) (actual time=0.016..0.018 rows=1 loops=1,146)

  • Index Cond: (customers_id = ct2.customers_id)
  • Filter: ((name)::text = 'PATRIS_KUNDENNUMMER'::text)
  • Rows Removed by Filter: 14
11. 8.640 24.066 ↓ 0.0 0 1,146

Index Scan using customers_pkey on customers c (cost=0.28..54.98 rows=1 width=26) (actual time=0.021..0.021 rows=0 loops=1,146)

  • Index Cond: (customers_id = ct1.customers_id)
  • Filter: ((NOT (alternatives: SubPlan 1 or hashed SubPlan 2)) OR (NOT (alternatives: SubPlan 3 or hashed SubPlan 4)))
  • Rows Removed by Filter: 1
12.          

SubPlan (for Index Scan)

13. 9.168 9.168 ↑ 1.0 1 1,146

Index Scan using idxkk_customers_to_tag_customers_id on kk_customers_to_tag ct_1 (cost=0.29..27.19 rows=1 width=0) (actual time=0.008..0.008 rows=1 loops=1,146)

  • Index Cond: (c.customers_id = customers_id)
  • Filter: ((name)::text = 'DBCONNECT_APINGV2_USER'::text)
  • Rows Removed by Filter: 5
14. 0.000 0.000 ↓ 0.0 0

Bitmap Heap Scan on kk_customers_to_tag ct_2 (cost=40.59..772.21 rows=1,055 width=4) (never executed)

  • Recheck Cond: ((name)::text = 'DBCONNECT_APINGV2_USER'::text)
15. 0.000 0.000 ↓ 0.0 0

Bitmap Index Scan on idx_name_kk_customers_to_tag (cost=0.00..40.33 rows=1,055 width=0) (never executed)

  • Index Cond: ((name)::text = 'DBCONNECT_APINGV2_USER'::text)
16. 6.258 6.258 ↑ 1.0 1 1,043

Index Scan using idxkk_customers_to_tag_customers_id on kk_customers_to_tag ct_3 (cost=0.29..27.19 rows=1 width=0) (actual time=0.006..0.006 rows=1 loops=1,043)

  • Index Cond: (c.customers_id = customers_id)
  • Filter: ((name)::text = 'DBCONNECT_APINGV2_PASSWORD'::text)
  • Rows Removed by Filter: 3
17. 0.000 0.000 ↓ 0.0 0

Bitmap Heap Scan on kk_customers_to_tag ct_4 (cost=36.48..768.68 rows=1,041 width=4) (never executed)

  • Recheck Cond: ((name)::text = 'DBCONNECT_APINGV2_PASSWORD'::text)
18. 0.000 0.000 ↓ 0.0 0

Bitmap Index Scan on idx_name_kk_customers_to_tag (cost=0.00..36.22 rows=1,041 width=0) (never executed)

  • Index Cond: ((name)::text = 'DBCONNECT_APINGV2_PASSWORD'::text)
Planning time : 2.925 ms
Execution time : 59.361 ms