explain.depesz.com

PostgreSQL's explain analyze made readable

Result: X251

Settings
# exclusive inclusive rows x rows loops node
1. 6.446 53,819.426 ↓ 2.0 2 1

Nested Loop (cost=2.00..322,674.61 rows=1 width=224) (actual time=40,264.894..53,819.426 rows=2 loops=1)

2. 20.921 53,806.204 ↓ 2.0 2 1

Nested Loop (cost=1.44..322,662.97 rows=1 width=77) (actual time=40,253.928..53,806.204 rows=2 loops=1)

3. 25.008 52,863.023 ↓ 30,742.0 30,742 1

Nested Loop (cost=1.01..322,662.26 rows=1 width=73) (actual time=29,674.506..52,863.023 rows=30,742 loops=1)

4. 48,441.909 48,441.909 ↓ 30,742.0 30,742 1

Index Scan using docs_post_idx1 on docs_post post (cost=0.57..322,659.40 rows=1 width=66) (actual time=29,672.380..48,441.909 rows=30,742 loops=1)

  • Index Cond: ((dat_sost >= (('now'::cstring)::date - '7 days'::interval)) AND (dat_sost <= (('now'::cstring)::date - '1 day'::interval)))
  • Filter: ((doc_n IS NOT NULL) AND ((ogai_sost_kod)::text = '45597'::text))
  • Rows Removed by Filter: 27,338
5. 4,396.106 4,396.106 ↑ 1.0 1 30,742

Index Scan using uchast_pkey on uchast uch (cost=0.43..2.85 rows=1 width=13) (actual time=0.142..0.143 rows=1 loops=30,742)

  • Index Cond: (uchast_id = post.uchast_id)
  • Filter: (uchast_vid = '1'::numeric)
6. 922.260 922.260 ↓ 0.0 0 30,742

Index Scan using kart_ul_pkey on kart_ul ul (cost=0.42..0.69 rows=1 width=17) (actual time=0.030..0.030 rows=0 loops=30,742)

  • Index Cond: (id = uch.ul_id)
  • Filter: ((inn)::text = '7705002602'::numeric)
  • Rows Removed by Filter: 0
7. 5.504 5.504 ↑ 1.0 1 2

Index Scan using decis_docs_post_id on decis (cost=0.56..2.98 rows=1 width=10) (actual time=2.751..2.752 rows=1 loops=2)

  • Index Cond: (docs_post_id = post.docs_id)
8.          

SubPlan (for Nested Loop)

9. 0.036 0.036 ↑ 1.0 1 2

Index Scan using s_stotv_pkey on s_stotv (cost=0.27..2.69 rows=1 width=15) (actual time=0.018..0.018 rows=1 loops=2)

  • Index Cond: (stotv_id = post.stotv_id)
10. 0.014 1.236 ↑ 1.0 1 2

Nested Loop (cost=0.87..5.72 rows=1 width=12) (actual time=0.616..0.618 rows=1 loops=2)

11. 1.168 1.168 ↑ 1.0 1 2

Index Scan using vehs_pkey on vehs v_1 (cost=0.43..2.85 rows=1 width=6) (actual time=0.584..0.584 rows=1 loops=2)

  • Index Cond: (vehs_id = post.vehs_id)
  • Filter: (vehs_vid = '1'::numeric)
12. 0.054 0.054 ↑ 1.0 1 2

Index Scan using kart_docs_pkey on kart_docs kdr (cost=0.43..2.85 rows=1 width=18) (actual time=0.027..0.027 rows=1 loops=2)

  • Index Cond: (id = v_1.regno_id)
Planning time : 2.053 ms
Execution time : 53,819.968 ms