explain.depesz.com

PostgreSQL's explain analyze made readable

Result: ih2n

Settings
# exclusive inclusive rows x rows loops node
1. 0.000 0.000 ↓ 0.0

Sort (cost=147,752.64..148,055.65 rows=121,206 width=40) (actual rows= loops=)

  • Sort Key: depertment_inc_cnt.cnt, imm_department.department_cd
2. 0.000 0.000 ↓ 0.0

Hash Left Join (cost=87,697.42..134,204.05 rows=121,206 width=40) (actual rows= loops=)

  • Hash Cond: ((imm_department.department_cd)::text = (depertment_inc_cnt.department_cd)::text)
3. 0.000 0.000 ↓ 0.0

Nested Loop Anti Join (cost=1,000.00..44,594.45 rows=121,206 width=32) (actual rows= loops=)

  • Join Filter: ((npbg_w_ss_jh_zk_work.soshiki_cd)::text = (imm_department.department_cd)::text)
4. 0.000 0.000 ↓ 0.0

Seq Scan on imm_department (cost=0.00..7,670.86 rows=121,207 width=32) (actual rows= loops=)

  • Filter: (((company_cd)::text <> (department_cd)::text) AND ((company_cd)::text = 'G-MAS0001'::text) AND ((department_set_cd)::text = 'G-MAS0001'::text) AND ((locale_id)::text = 'ja'::text) AND (start_date = '1900-01-01'::date))
5. 0.000 0.000 ↓ 0.0

Materialize (cost=1,000.00..35,105.49 rows=1 width=32) (actual rows= loops=)

6. 0.000 0.000 ↓ 0.0

Gather (cost=1,000.00..35,105.48 rows=1 width=32) (actual rows= loops=)

  • Workers Planned: 2
7. 0.000 0.000 ↓ 0.0

Parallel Seq Scan on npbg_w_ss_jh_zk_work (cost=0.00..34,105.38 rows=1 width=32) (actual rows= loops=)

  • Filter: (((soshiki_joho_teishi_ymd)::text >= '20200213'::text) AND ((del_flg)::text = '0'::text) AND (torikomi_dt = '2020-02-12 20:53:27.847'::timestamp without time zone))
8. 0.000 0.000 ↓ 0.0

Hash (cost=84,264.72..84,264.72 rows=119,736 width=40) (actual rows= loops=)

9. 0.000 0.000 ↓ 0.0

Subquery Scan on depertment_inc_cnt (cost=49,803.69..84,264.72 rows=119,736 width=40) (actual rows= loops=)

10. 0.000 0.000 ↓ 0.0

Finalize GroupAggregate (cost=49,803.69..83,067.36 rows=119,736 width=40) (actual rows= loops=)

  • Group Key: imm_department_inc_ath.department_cd
11. 0.000 0.000 ↓ 0.0

Gather Merge (cost=49,803.69..80,672.64 rows=239,472 width=40) (actual rows= loops=)

  • Workers Planned: 2
12. 0.000 0.000 ↓ 0.0

Partial GroupAggregate (cost=48,803.67..52,031.61 rows=119,736 width=40) (actual rows= loops=)

  • Group Key: imm_department_inc_ath.department_cd
13. 0.000 0.000 ↓ 0.0

Sort (cost=48,803.67..49,480.53 rows=270,744 width=32) (actual rows= loops=)

  • Sort Key: imm_department_inc_ath.department_cd
14. 0.000 0.000 ↓ 0.0

Parallel Seq Scan on imm_department_inc_ath (cost=0.00..17,895.16 rows=270,744 width=32) (actual rows= loops=)

  • Filter: (((company_cd)::text = 'G-MAS0001'::text) AND ((department_set_cd)::text = 'G-MAS0001'::text))