explain.depesz.com

PostgreSQL's explain analyze made readable

Result: mYbj

Settings
# exclusive inclusive rows x rows loops node
1. 8,285.408 167,025.425 ↓ 44,759.3 134,278 1

GroupAggregate (cost=1,217,044.43..1,234,087.73 rows=3 width=111) (actual time=139,908.727..167,025.425 rows=134,278 loops=1)

  • Group Key: asm.pzpackage, asm.pzclass, asm.pzcacheconfigid
  • Filter: ((((max(usage.pxlastuse) IS NOT NULL) AND (max(usage.pxlastuse) < '2019-10-27 06:00:15.462'::timestamp without time zone)) OR (max(usage.pxlastuse) IS NULL)) AND ((max(ra_entry.pxcreatedatetime) IS NULL) OR (max(ra_entry.pxcre
  • Rows Removed by Filter: 5629
2. 5,789.146 158,740.017 ↓ 135.1 42,962,640 1

Merge Left Join (cost=1,217,044.43..1,219,429.14 rows=317,959 width=658) (actual time=139,908.714..158,740.017 rows=42,962,640 loops=1)

  • Merge Cond: (((asm.pzpackage)::text = (ra_entry.pzpackage)::text) AND ((asm.pzclass)::text = (ra_entry.pzclass)::text))
  • Join Filter: ((ra_entry.pzcacheconfigid)::text = (asm.pzcacheconfigid)::text)
3. 135,151.649 152,950.854 ↓ 135.1 42,962,640 1

Sort (cost=1,217,042.20..1,217,837.09 rows=317,959 width=134) (actual time=139,908.691..152,950.854 rows=42,962,640 loops=1)

  • Sort Key: asm.pzpackage, asm.pzclass
  • Sort Method: external merge Disk: 6438712kB
4. 12,552.059 17,799.205 ↓ 135.1 42,962,640 1

Hash Right Join (cost=32,228.06..1,187,983.16 rows=317,959 width=134) (actual time=314.772..17,799.205 rows=42,962,640 loops=1)

  • Hash Cond: (((ac_shortcut.pzcacheconfigid)::text = (asm.pzcacheconfigid)::text) AND ((ac_shortcut.pzpackage)::text = (asm.pzpackage)::text) AND ((ac_shortcut.pzclass)::text = (asm.pzclass)::text))
5. 4,932.619 4,932.619 ↑ 1.0 4,567,053 1

Seq Scan on pr_sys_appcache_shortcut ac_shortcut (cost=0.00..1,101,196.16 rows=4,567,053 width=130) (actual time=0.029..4,932.619 rows=4,567,053 loops=1)

  • Filter: ((pzcacheconfigid)::text = '-560251499'::text)
6. 46.446 314.527 ↑ 1.0 155,525 1

Hash (cost=29,482.49..29,482.49 rows=156,890 width=119) (actual time=314.527..314.527 rows=155,525 loops=1)

  • Buckets: 262144 Batches: 1 Memory Usage: 24432kB
7. 46.562 268.081 ↑ 1.0 155,525 1

Hash Right Join (cost=23,217.60..29,482.49 rows=156,890 width=119) (actual time=195.801..268.081 rows=155,525 loops=1)

  • Hash Cond: (((usage.pzpackage)::text = (asm.pzpackage)::text) AND ((usage.pzclass)::text = (asm.pzclass)::text))
8. 25.943 25.943 ↑ 1.0 20,184 1

Seq Scan on pr4_log_rule_usage usage (cost=0.00..6,098.84 rows=20,184 width=113) (actual time=0.009..25.943 rows=20,184 loops=1)

9. 46.850 195.576 ↑ 1.1 139,907 1

Hash (cost=20,864.26..20,864.26 rows=156,890 width=111) (actual time=195.576..195.576 rows=139,907 loops=1)

  • Buckets: 262144 Batches: 1 Memory Usage: 21936kB
10. 148.726 148.726 ↑ 1.1 139,907 1

Seq Scan on pr_assembledclasses asm (cost=0.00..20,864.26 rows=156,890 width=111) (actual time=0.023..148.726 rows=139,907 loops=1)

  • Filter: ((pzlastmodified < '2019-11-25 05:00:15.462'::timestamp without time zone) AND ((pzpackage)::text <> 'com/pegarules/generated'::text) AND ((pzclass)::text !~~ '%$%'::text) AND ((pzcach
  • Rows Removed by Filter: 197988
11. 0.008 0.017 ↓ 0.0 0 1

Sort (cost=2.23..2.23 rows=1 width=1,702) (actual time=0.017..0.017 rows=0 loops=1)

  • Sort Key: ra_entry.pzpackage, ra_entry.pzclass
  • Sort Method: quicksort Memory: 25kB
12. 0.009 0.009 ↓ 0.0 0 1

Index Scan using cache_entry_rule on pr_sys_cache_entry ra_entry (cost=0.14..2.22 rows=1 width=1,702) (actual time=0.009..0.009 rows=0 loops=1)

  • Index Cond: ((pzcacheconfigid)::text = '-560251499'::text)