explain.depesz.com

PostgreSQL's explain analyze made readable

Result: Ib8t : Test

Settings
# exclusive inclusive rows x rows loops node
1. 126.617 28,448.541 ↓ 1.1 32,389 1

Sort (cost=108,555.94..108,632.85 rows=30,764 width=99) (actual time=28,417.434..28,448.541 rows=32,389 loops=1)

  • Sort Key: discriminator0.created_at DESC
  • Sort Method: external merge Disk: 3,624kB
  • JIT:
  • Functions: 35
  • Options: Inlining false, Optimization false, Expressions true, Deforming true
  • Timing: Generation 4.489 ms, Inlining 0.000 ms, Optimization 1.883 ms, Emission 29.555 ms, Total 35.927 ms
2. 193.051 28,321.924 ↓ 1.1 32,389 1

Nested Loop Left Join (cost=0.56..105,276.60 rows=30,764 width=99) (actual time=13,490.885..28,321.924 rows=32,389 loops=1)

3. 501.056 501.056 ↓ 1.1 32,389 1

Index Scan using discriminator0_timestamp_vehicle_idx on discriminator0 (cost=0.43..32,212.10 rows=30,764 width=83) (actual time=139.513..501.056 rows=32,389 loops=1)

  • Index Cond: (("timestamp" > '2020-07-24 16:18:00+00'::timestamp with time zone) AND ("timestamp" < '2020-07-31 16:18:00+00'::timestamp with time zone) AND (vehicle = 'cr060'::text))
4. 129.556 27,627.817 ↑ 1.0 1 32,389

Limit (cost=0.13..2.35 rows=1 width=78) (actual time=0.852..0.853 rows=1 loops=32,389)

5. 660.391 27,498.261 ↑ 1.0 1 32,389

Custom Scan (ChunkAppend) on discriminator4 (cost=0.13..2.35 rows=1 width=78) (actual time=0.849..0.849 rows=1 loops=32,389)

  • Order: discriminator4."timestamp" DESC
  • Chunks excluded during runtime: 2
6. 0.000 0.000 ↓ 0.0 0

Index Scan Backward using _hyper_4_17_chunk_discriminator4_timestamp_idx1 on _hyper_4_17_chunk (cost=0.13..2.35 rows=1 width=24) (never executed)

  • Index Cond: (("timestamp" <= discriminator0."timestamp") AND ("timestamp" >= '2020-07-24 16:18:00+00'::timestamp with time zone))
  • Filter: (vehicle = discriminator0.vehicle)
7. 0.000 0.000 ↓ 0.0 0

Index Scan Backward using _hyper_4_11_chunk_discriminator4_timestamp_idx1 on _hyper_4_11_chunk (cost=0.14..2.36 rows=1 width=24) (never executed)

  • Index Cond: (("timestamp" <= discriminator0."timestamp") AND ("timestamp" >= '2020-07-24 16:18:00+00'::timestamp with time zone))
  • Filter: (vehicle = discriminator0.vehicle)
8. 10,693.280 10,693.280 ↑ 335.0 1 15,520

Index Scan Backward using _hyper_4_30_chunk_discriminator4_timestamp_idx1 on _hyper_4_30_chunk (cost=0.43..328.70 rows=335 width=24) (actual time=0.689..0.689 rows=1 loops=15,520)

  • Index Cond: (("timestamp" <= discriminator0."timestamp") AND ("timestamp" >= '2020-07-24 16:18:00+00'::timestamp with time zone))
  • Filter: (vehicle = discriminator0.vehicle)
  • Rows Removed by Filter: 1,398
9. 16,144.590 16,144.590 ↑ 991.0 1 16,870

Index Scan Backward using _hyper_4_22_chunk_discriminator4_timestamp_idx1 on _hyper_4_22_chunk (cost=0.43..999.27 rows=991 width=24) (actual time=0.957..0.957 rows=1 loops=16,870)

  • Index Cond: (("timestamp" <= discriminator0."timestamp") AND ("timestamp" >= '2020-07-24 16:18:00+00'::timestamp with time zone))
  • Filter: (vehicle = discriminator0.vehicle)
  • Rows Removed by Filter: 153
Planning time : 7.397 ms
Execution time : 28,480.183 ms