explain.depesz.com

PostgreSQL's explain analyze made readable

Result: OpT4

Settings
# exclusive inclusive rows x rows loops node
1. 29,804.254 146,022.259 ↑ 241.0 1 1

GroupAggregate (cost=37,671.41..18,690,784.23 rows=241 width=18) (actual time=146,022.257..146,022.259 rows=1 loops=1)

  • Group Key: "PC0".companynum
2. 59,080.482 116,218.005 ↑ 18.0 50,078,525 1

Merge Right Join (cost=37,671.41..14,174,912.23 rows=903,173,917 width=19) (actual time=313.902..116,218.005 rows=50,078,525 loops=1)

  • Merge Cond: (("HJGROUP".hjwaribikigrcd)::text = ("PC0".hjwaribikigrcd)::text)
3. 30,705.429 30,705.429 ↑ 1.0 4,996,901 1

Index Only Scan using idx_qr001_hjcode_null on pr_kddi_hjfront_data_qr001 "HJGROUP" (cost=0.43..576,552.44 rows=5,065,867 width=9) (actual time=0.065..30,705.429 rows=4,996,901 loops=1)

  • Heap Fetches: 5,053,809
4. 26,289.194 26,432.094 ↓ 332.1 50,078,525 1

Materialize (cost=37,670.98..38,424.88 rows=150,780 width=28) (actual time=131.655..26,432.094 rows=50,078,525 loops=1)

5. 28.473 142.900 ↑ 8.0 18,866 1

Sort (cost=37,670.98..38,047.93 rows=150,780 width=28) (actual time=131.652..142.900 rows=18,866 loops=1)

  • Sort Key: "PC0".hjwaribikigrcd USING ~<~
  • Sort Method: quicksort Memory: 2,242kB
6. 28.423 114.427 ↑ 8.0 18,866 1

Nested Loop Left Join (cost=10.74..21,093.83 rows=150,780 width=28) (actual time=13.967..114.427 rows=18,866 loops=1)

7. 41.049 54.432 ↓ 21.7 5,262 1

Bitmap Heap Scan on pr_kddi_hjfront_data_qr001 "PC0" (cost=10.32..949.51 rows=243 width=39) (actual time=13.939..54.432 rows=5,262 loops=1)

  • Recheck Cond: ((companynum)::text = '01496133D'::text)
  • Heap Blocks: exact=3,473
8. 13.383 13.383 ↓ 21.7 5,266 1

Bitmap Index Scan on idx_qr001_comanynum (cost=0.00..10.25 rows=243 width=0) (actual time=13.383..13.383 rows=5,266 loops=1)

  • Index Cond: ((companynum)::text = '01496133D'::text)
9. 31.572 31.572 ↑ 6.7 3 5,262

Index Only Scan using idx_qr001_hjcode_notnull on pr_kddi_hjfront_data_qr001 "ACCOUNT" (cost=0.42..82.70 rows=20 width=11) (actual time=0.003..0.006 rows=3 loops=5,262)

  • Index Cond: (togoseikyusakiacc = ("PC0".togoseikyusakiacc)::text)
  • Heap Fetches: 13,642