explain.depesz.com

PostgreSQL's explain analyze made readable

Result: A2WN : org

Settings
# exclusive inclusive rows x rows loops node
1. 0.018 292.446 ↓ 2.0 2 1

Sort (cost=68,672.88..68,672.89 rows=1 width=738) (actual time=292.446..292.446 rows=2 loops=1)

  • Sort Key: cmmparty.party_code_, cmmregdoc.frame_no_
  • Sort Method: quicksort Memory: 26kB
2.          

CTE mddealer

3. 0.347 4.744 ↓ 2.2 614 1

Hash Join (cost=188.15..538.08 rows=277 width=6) (actual time=2.928..4.744 rows=614 loops=1)

  • Hash Cond: ((relation.from_organization_id_)::text = (mst.organization_id_)::text)
4. 1.975 1.975 ↓ 1.1 614 1

Seq Scan on cmm_party_relation relation (cost=0.00..342.82 rows=579 width=36) (actual time=0.483..1.975 rows=614 loops=1)

  • Filter: ((party_relation_type_id_)::text = 'C028DEALERUNITMAINDEALER'::text)
  • Rows Removed by Filter: 6664
5. 0.948 2.422 ↑ 1.0 3,528 1

Hash (cost=142.51..142.51 rows=3,651 width=42) (actual time=2.422..2.422 rows=3,528 loops=1)

  • Buckets: 1024 Batches: 1 Memory Usage: 262kB
6. 1.474 1.474 ↑ 1.0 3,528 1

Seq Scan on cmm_site_mst mst (cost=0.00..142.51 rows=3,651 width=42) (actual time=0.004..1.474 rows=3,528 loops=1)

7. 0.022 292.428 ↓ 2.0 2 1

Nested Loop (cost=18.60..68,134.79 rows=1 width=738) (actual time=81.097..292.428 rows=2 loops=1)

8. 0.014 292.394 ↓ 2.0 2 1

Nested Loop (cost=18.46..68,134.61 rows=1 width=258) (actual time=81.068..292.394 rows=2 loops=1)

9. 0.865 292.360 ↓ 2.0 2 1

Nested Loop (cost=18.05..68,130.16 rows=1 width=259) (actual time=81.044..292.360 rows=2 loops=1)

  • Join Filter: ((cmmorginfo.party_id_)::text = (cmmparty.party_id_)::text)
  • Rows Removed by Join Filter: 7952
10. 1.112 290.433 ↓ 2.0 2 1

Nested Loop (cost=18.05..67,964.71 rows=1 width=324) (actual time=79.938..290.433 rows=2 loops=1)

  • Join Filter: ((cmmregdoc.organization_id_)::text = (cmmorginfo.party_id_)::text)
  • Rows Removed by Join Filter: 7786
11. 0.093 288.207 ↓ 2.0 2 1

Nested Loop (cost=18.05..67,667.53 rows=1 width=272) (actual time=79.910..288.207 rows=2 loops=1)

12. 0.468 242.514 ↓ 75.0 75 1

Nested Loop (cost=17.49..67,662.23 rows=1 width=223) (actual time=21.500..242.514 rows=75 loops=1)

  • Join Filter: ((mddealer.site_code_)::text = (cmmregdoc.site_id_)::text)
13. 1.072 7.498 ↓ 2.2 614 1

Merge Join (cost=17.06..220.12 rows=277 width=140) (actual time=5.810..7.498 rows=614 loops=1)

  • Merge Cond: ((cmmsitemst.site_id_)::text = (mddealer.site_code_)::text)
14. 1.100 1.100 ↑ 1.0 3,528 1

Index Scan using cmm_site_mst_idx01 on cmm_site_mst cmmsitemst (cost=0.28..190.06 rows=3,651 width=42) (actual time=0.036..1.100 rows=3,528 loops=1)

15. 0.423 5.326 ↓ 2.2 614 1

Sort (cost=16.78..17.47 rows=277 width=98) (actual time=5.195..5.326 rows=614 loops=1)

  • Sort Key: mddealer.site_code_
  • Sort Method: quicksort Memory: 53kB
16. 4.903 4.903 ↓ 2.2 614 1

CTE Scan on mddealer (cost=0.00..5.54 rows=277 width=98) (actual time=2.930..4.903 rows=614 loops=1)

17. 234.548 234.548 ↓ 0.0 0 614

Index Scan using cmm_registration_doc_idx02 on cmm_registration_document cmmregdoc (cost=0.43..243.46 rows=1 width=194) (actual time=0.371..0.382 rows=0 loops=614)

  • Index Cond: ((site_id_)::text = (cmmsitemst.site_id_)::text)
  • Filter: (((request_faktur_date_)::text >= '20191005'::text) AND ((request_faktur_date_)::text <= '20191105'::text))
  • Rows Removed by Filter: 237
18. 45.600 45.600 ↓ 0.0 0 75

Index Scan using cmm_registration_document_dtl_idx01 on cmm_registration_document_dtl cmmregdocdtl (cost=0.56..5.28 rows=1 width=73) (actual time=0.608..0.608 rows=0 loops=75)

  • Index Cond: ((registration_document_id_)::text = (cmmregdoc.registration_document_id_)::text)
  • Filter: ((print_times_ > 1) AND ((status_)::text = 'C176WAITINGFORALLOCAPPROVE'::text))
  • Rows Removed by Filter: 2
19. 1.114 1.114 ↓ 1.0 3,894 2

Seq Scan on cmm_organization_info cmmorginfo (cost=0.00..248.75 rows=3,875 width=52) (actual time=0.005..0.557 rows=3,894 loops=2)

20. 1.062 1.062 ↑ 1.0 3,977 2

Seq Scan on cmm_party_info cmmparty (cost=0.00..115.20 rows=4,020 width=43) (actual time=0.004..0.531 rows=3,977 loops=2)

21. 0.020 0.020 ↑ 1.0 1 2

Index Scan using pk_product_add on cmm_product cmmpro (cost=0.42..4.44 rows=1 width=73) (actual time=0.010..0.010 rows=1 loops=2)

  • Index Cond: ((product_id_)::text = (cmmregdoc.product_id_)::text)
22. 0.012 0.012 ↑ 1.0 1 2

Index Scan using cmm_area_mst_pkey on cmm_area_mst cmmareamst (cost=0.14..0.17 rows=1 width=614) (actual time=0.006..0.006 rows=1 loops=2)

  • Index Cond: ((geography_id_)::text = (cmmsitemst.area_id_)::text)
Planning time : 6.552 ms
Execution time : 292.836 ms