explain.depesz.com

PostgreSQL's explain analyze made readable

Result: 3nQD

Settings

Optimization(s) for this plan:

# exclusive inclusive rows x rows loops node
1. 0.000 0.000 ↓ 0.0

Merge Join (cost=6,442.85..6,445.38 rows=1 width=4) (actual rows= loops=)

  • Merge Cond: (u0.resource_id = "resourceManager_V1_resourcegenericproperty".resource_id)
2. 0.000 0.000 ↓ 0.0

Unique (cost=6,434.68..6,436.60 rows=47 width=4) (actual rows= loops=)

3. 0.000 0.000 ↓ 0.0

Sort (cost=6,434.68..6,435.64 rows=385 width=4) (actual rows= loops=)

  • Sort Key: u0.resource_id
4. 0.000 0.000 ↓ 0.0

Nested Loop Left Join (cost=2,321.69..6,418.14 rows=385 width=4) (actual rows= loops=)

  • Filter: ((u3.status >= 3) OR (u3.status IS NULL))
5. 0.000 0.000 ↓ 0.0

Hash Join (cost=2,321.40..6,043.37 rows=385 width=8) (actual rows= loops=)

  • Hash Cond: (u0.resource_id = u0_1.id)
6. 0.000 0.000 ↓ 0.0

Nested Loop (cost=2,300.44..6,019.95 rows=455 width=8) (actual rows= loops=)

7. 0.000 0.000 ↓ 0.0

Hash Join (cost=2,300.15..5,494.20 rows=863 width=8) (actual rows= loops=)

  • Hash Cond: (u4.id = u2.event_id)
8. 0.000 0.000 ↓ 0.0

Seq Scan on event_event u4 (cost=0.00..3,070.25 rows=8,376 width=4) (actual rows= loops=)

  • Filter: (((start <= '2019-03-12 15:25:56.931162+01'::timestamp with time zone) AND ("end" >= '2019-03-12 15:40:56.931162+01'::timestamp with time zone)) OR (("end" > '2019-03-12 15:25:56.931162+01'::timestamp wit (...)
9. 0.000 0.000 ↓ 0.0

Hash (cost=2,189.85..2,189.85 rows=8,824 width=12) (actual rows= loops=)

10. 0.000 0.000 ↓ 0.0

Seq Scan on "meeting_V1_reservation" u2 (cost=0.00..2,189.85 rows=8,824 width=12) (actual rows= loops=)

  • Filter: "isValid
11. 0.000 0.000 ↓ 0.0

Index Scan using "meeting_V1_resourcemanager_reservation_id" on "meeting_V1_resourcemanager" u0 (cost=0.29..0.60 rows=1 width=8) (actual rows= loops=)

  • Index Cond: (reservation_id = u2.id)
  • Filter: ((NOT released) AND (NOT finished))
12. 0.000 0.000 ↓ 0.0

Hash (cost=20.46..20.46 rows=40 width=4) (actual rows= loops=)

13. 0.000 0.000 ↓ 0.0

Seq Scan on "resourceManager_V1_resource" u0_1 (cost=0.00..20.46 rows=40 width=4) (actual rows= loops=)

  • Filter: (id = ANY ('{783,784,785,786,787,788,790,791,792,793,794,795,796,797,798,799,800,801,802,803,804,805,827,828,783,784,785,786,787,788,790,791,792,793,794,795,796,797,798,799}'::integer[]))
14. 0.000 0.000 ↓ 0.0

Index Scan using instance_moduleinstance_pkey on instance_moduleinstance u3 (cost=0.29..0.96 rows=1 width=6) (actual rows= loops=)

  • Index Cond: (u2.instance_id = id)
15. 0.000 0.000 ↓ 0.0

Sort (cost=8.17..8.18 rows=1 width=4) (actual rows= loops=)

  • Sort Key: "resourceManager_V1_resourcegenericproperty".resource_id
16. 0.000 0.000 ↓ 0.0

Index Scan using "resourceManager_V1_resourcegenericproperty_value_like" on "resourceManager_V1_resourcegenericproperty" (cost=0.14..8.16 rows=1 width=4) (actual rows= loops=)

  • Index Cond: ((value)::text = '4'::text)
  • Filter: ((name)::text = 'sensor_resource_state'::text)