explain.depesz.com

PostgreSQL's explain analyze made readable

Result: TtK6

Settings
# exclusive inclusive rows x rows loops node
1. 27.435 30.173 ↑ 1.0 1 1

Aggregate (cost=2,508.26..2,508.28 rows=1 width=32) (actual time=30.172..30.173 rows=1 loops=1)

  • Output: round((sum(((((patient_therapy_statistics_vent_2019_jan_01_10.channel_stats -> 'tidVolExhaled'::text) ->> 'avgValue'::text))::numeric * (((patient_therapy_statistics_vent_2019_jan_01_10.channel_stats -> 'tidVolExhaled'::text) ->> 'total_duration'::text))::numeric)) / sum((((patient_therapy_statistics_vent_2019_jan_01_10.channel_stats -> 'tidVolExhaled'::text) ->> 'total_duration'::text))::numeric)), 2)
  • Buffers: shared hit=2607
2. 0.255 2.738 ↓ 1.1 2,592 1

Append (cost=0.56..2,423.17 rows=2,269 width=522) (actual time=0.016..2.738 rows=2,592 loops=1)

  • Buffers: shared hit=2607
3. 2.483 2.483 ↓ 1.1 2,592 1

Index Scan using pk_pts_vent2_2019_jan_01_10 on ptd.patient_therapy_statistics_vent_2019_jan_01_10 (cost=0.56..2,423.17 rows=2,269 width=522) (actual time=0.015..2.483 rows=2,592 loops=1)

  • Output: patient_therapy_statistics_vent_2019_jan_01_10.channel_stats
  • Index Cond: ((patient_therapy_statistics_vent_2019_jan_01_10.patient_id = 500) AND (patient_therapy_statistics_vent_2019_jan_01_10.start_time >= '2019-01-01 00:00:00'::timestamp without time zone) AND (patient_therapy_statistics_vent_2019_jan_01_10.start_time <= '2019-01-10 00:00:00'::timestamp without time zone))
  • Filter: (patient_therapy_statistics_vent_2019_jan_01_10.end_time <= '2019-01-10 00:00:00'::timestamp without time zone)
  • Rows Removed by Filter: 1
  • Buffers: shared hit=2607