explain.depesz.com

PostgreSQL's explain analyze made readable

Result: 0Dnb : Teacher birthday without date check

Settings
# exclusive inclusive rows x rows loops node
1. 379.977 31,374.837 ↓ 1.1 922,533 1

Seq Scan on dcteacher t (cost=0.00..59,488,203.91 rows=846,072 width=4) (actual time=0.005..31,374.837 rows=922,533 loops=1)

  • Filter: ((NOT excluded) OR ((SubPlan 1) AND (SubPlan 2)))
  • Rows Removed by Filter: 594269
  • Buffers: shared hit=10711370 read=153498
  • I/O Timings: read=22888.930
2.          

SubPlan (for Seq Scan)

3. 695.940 28,610.688 ↓ 0.0 0 894,084

Nested Loop (cost=0.99..298.77 rows=14 width=0) (actual time=0.032..0.032 rows=0 loops=894,084)

  • Buffers: shared hit=7901429 read=144292
  • I/O Timings: read=22820.988
4. 22,352.100 22,352.100 ↑ 21.0 1 894,084

Index Scan using dcproposal_createduserid on dcproposal (cost=0.43..88.23 rows=21 width=4) (actual time=0.015..0.025 rows=1 loops=894,084)

  • Index Cond: (createduserid = t.teacherid)
  • Buffers: shared hit=3334977 read=120510
  • I/O Timings: read=20661.252
5. 5,562.648 5,562.648 ↓ 0.0 0 794,664

Index Scan using proposalworkflowstatus_altindex2 on proposalworkflowstatus (cost=0.56..10.01 rows=2 width=4) (actual time=0.007..0.007 rows=0 loops=794,664)

  • Index Cond: (proposalid = dcproposal.proposalid)
  • Filter: (workflowstatusid = 3)
  • Rows Removed by Filter: 2
  • Buffers: shared hit=4566452 read=23782
  • I/O Timings: read=2159.736
6. 0.000 2,384.172 ↑ 1.0 1 340,596

Subquery Scan on x (cost=16.91..16.94 rows=1 width=4) (actual time=0.007..0.007 rows=1 loops=340,596)

  • Buffers: shared hit=2793449 read=1330
  • I/O Timings: read=15.297
7. 340.596 2,384.172 ↑ 1.0 1 340,596

GroupAggregate (cost=16.91..16.93 rows=1 width=12) (actual time=0.007..0.007 rows=1 loops=340,596)

  • Group Key: teacherdeactivationevent.teacherid, teacherdeactivationeventreason.reason
  • Buffers: shared hit=2793449 read=1330
  • I/O Timings: read=15.297
8. 340.596 2,043.576 ↑ 1.0 1 340,596

Sort (cost=16.91..16.92 rows=1 width=8) (actual time=0.006..0.006 rows=1 loops=340,596)

  • Sort Key: teacherdeactivationeventreason.reason
  • Sort Method: quicksort Memory: 25kB
  • Buffers: shared hit=2793449 read=1330
  • I/O Timings: read=15.297
9. 313.644 1,702.980 ↑ 1.0 1 340,596

Nested Loop (cost=0.85..16.90 rows=1 width=8) (actual time=0.005..0.005 rows=1 loops=340,596)

  • Buffers: shared hit=2793449 read=1330
  • I/O Timings: read=15.297
10. 681.192 681.192 ↑ 1.0 1 340,596

Index Scan using teacherdeactivationevent_teacherid on teacherdeactivationevent (cost=0.43..8.45 rows=1 width=8) (actual time=0.002..0.002 rows=1 loops=340,596)

  • Index Cond: (teacherid = t.teacherid)
  • Buffers: shared hit=1376008 read=568
  • I/O Timings: read=6.242
11. 708.144 708.144 ↑ 1.0 1 354,072

Index Scan using teacherdeactivationeventreason_teacherdeactivationeventid on teacherdeactivationeventreason (cost=0.43..8.45 rows=1 width=8) (actual time=0.002..0.002 rows=1 loops=354,072)

  • Index Cond: (teacherdeactivationeventid = teacherdeactivationevent.id)
  • Buffers: shared hit=1417441 read=762
  • I/O Timings: read=9.055
Planning time : 0.677 ms
Execution time : 31,417.429 ms