explain.depesz.com

PostgreSQL's explain analyze made readable

Result: JkBj

Settings
# exclusive inclusive rows x rows loops node
1. 7.380 7.380 ↓ 1,578.0 1,578 1

CTE Scan on scores_info (cost=35.02..35.04 rows=1 width=574) (actual time=0.059..7.380 rows=1,578 loops=1)

2.          

CTE scores_info

3. 2.306 6.482 ↓ 1,578.0 1,578 1

Nested Loop (cost=1.95..35.02 rows=1 width=201) (actual time=0.056..6.482 rows=1,578 loops=1)

  • Join Filter: ((((mv.levelcode)::text = 'K'::text) AND ((stu.grade)::text <> 'K'::text) AND ((mv.objectivecode)::text ~~ '%GR1%'::text)) OR (((mv.levelcode)::text = 'K'::text) AND ((stu.grade)::text = 'K'::text) AND ((mv.objectivecode)::text !~~ '%GR1%'::text)) OR ((mv.levelcode)::text <> 'K'::text))
4. 0.383 1.020 ↓ 1,578.0 1,578 1

Nested Loop (cost=1.53..34.51 rows=1 width=96) (actual time=0.043..1.020 rows=1,578 loops=1)

  • Join Filter: (stu.participantid = x.participantid)
5. 0.006 0.057 ↓ 20.0 20 1

Nested Loop (cost=0.84..25.82 rows=1 width=58) (actual time=0.026..0.057 rows=20 loops=1)

6. 0.010 0.010 ↑ 1.0 1 1

Index Scan using udx_dim_participant on dim_participant stu (cost=0.42..8.44 rows=1 width=22) (actual time=0.010..0.010 rows=1 loops=1)

  • Index Cond: ((administrationid = 592030) AND (studentidcode = 104575))
7. 0.041 0.041 ↓ 20.0 20 1

Index Scan using idx_dim_assessmentparticipant_2 on dim_assessmentparticipant asmt (cost=0.42..17.37 rows=1 width=36) (actual time=0.015..0.041 rows=20 loops=1)

  • Index Cond: ((administrationid = 592030) AND (participantid = stu.participantid))
  • Filter: (((is_reportable)::text = 'YES'::text) AND ((reportphase)::text = 'IR'::text) AND ((testingstatus)::text = 'ReportingReady'::text) AND (COALESCE(NULLIF((nottestedcode)::text, ''::text), '*'::text) = ANY ('{*,DN}'::text[])))
8. 0.580 0.580 ↓ 79.0 79 20

Index Scan using idx_fact_itemresult_1 on fact_itemresult x (cost=0.69..8.67 rows=1 width=78) (actual time=0.007..0.029 rows=79 loops=20)

  • Index Cond: ((administrationid = 592030) AND (participantid = asmt.participantid) AND (assessmentparticipantid = asmt.assessmentparticipantid))
9. 3.156 3.156 ↑ 1.0 1 1,578

Index Scan using udx_mv_metadata_1 on mv_metadata mv (cost=0.41..0.46 rows=1 width=104) (actual time=0.002..0.002 rows=1 loops=1,578)

  • Index Cond: ((administrationid = 592030) AND (subtestid = x.subtestid) AND (assessmentlevelid = x.assessmentlevelid) AND (assessmentformid = x.assessmentformid) AND (objectiveid = x.objectiveid) AND (assessmentitemid = x.assessmentitemid))
  • Filter: ((((levelcode)::text = 'K'::text) AND ((objectivecode)::text ~~ '%GR1%'::text)) OR (((levelcode)::text = 'K'::text) AND ((objectivecode)::text !~~ '%GR1%'::text)) OR ((levelcode)::text <> 'K'::text))
Planning time : 1.956 ms
Execution time : 7.539 ms