explain.depesz.com

PostgreSQL's explain analyze made readable

Result: VUu

Settings
# exclusive inclusive rows x rows loops node
1. 0.058 7.644 ↑ 90.0 62 1

Sort (cost=675.65..678.44 rows=5,583 width=42) (actual time=7.638..7.644 rows=62 loops=1)

  • Sort Key: t.created_at
  • Sort Method: quicksort Memory: 29kB
2. 1.221 7.586 ↑ 90.0 62 1

Hash Join (cost=236.81..606.16 rows=5,583 width=42) (actual time=3.556..7.586 rows=62 loops=1)

  • Hash Cond: ((t.elevator_id)::text = (e.sfid)::text)
3. 2.872 2.872 ↓ 1.0 12,943 1

Seq Scan on ticket t (cost=0.00..345.42 rows=12,807 width=43) (actual time=0.010..2.872 rows=12,943 loops=1)

4. 0.171 3.493 ↓ 1.2 770 1

Hash (cost=234.57..234.57 rows=640 width=37) (actual time=3.493..3.493 rows=770 loops=1)

  • Buckets: 1024 Batches: 1 Memory Usage: 55kB
5. 0.319 3.322 ↓ 1.2 770 1

Hash Join (cost=135.41..234.57 rows=640 width=37) (actual time=1.627..3.322 rows=770 loops=1)

  • Hash Cond: ((e.building__c)::text = (b.sfid)::text)
6. 1.427 1.427 ↓ 1.0 1,469 1

Seq Scan on elevator__c e (cost=0.00..96.14 rows=1,468 width=48) (actual time=0.020..1.427 rows=1,469 loops=1)

  • Filter: ((name)::text !~~* 'demo%'::text)
  • Rows Removed by Filter: 11
7. 0.252 1.576 ↓ 1.8 1,039 1

Hash (cost=133.36..133.36 rows=587 width=27) (actual time=1.576..1.576 rows=1,039 loops=1)

  • Buckets: 2048 (originally 1024) Batches: 1 (originally 1) Memory Usage: 70kB
8. 0.539 1.324 ↓ 1.8 1,039 1

Hash Left Join (cost=43.11..133.36 rows=587 width=27) (actual time=0.561..1.324 rows=1,039 loops=1)

  • Hash Cond: ((b.contract__c)::text = (c.sfid)::text)
  • Filter: ((c.sfid IS NULL) OR ((c.status)::text <> ALL ('{Activated,Cancelled}'::text[])))
  • Rows Removed by Filter: 371
9. 0.258 0.258 ↓ 1.0 1,410 1

Seq Scan on buildings__c b (cost=0.00..87.04 rows=1,346 width=38) (actual time=0.008..0.258 rows=1,410 loops=1)

10. 0.155 0.527 ↓ 1.1 669 1

Hash (cost=40.90..40.90 rows=633 width=27) (actual time=0.527..0.527 rows=669 loops=1)

  • Buckets: 1024 Batches: 1 Memory Usage: 47kB
11. 0.372 0.372 ↓ 1.1 669 1

Seq Scan on contract c (cost=0.00..40.90 rows=633 width=27) (actual time=0.008..0.372 rows=669 loops=1)

Planning time : 1.886 ms
Execution time : 7.724 ms