explain.depesz.com

PostgreSQL's explain analyze made readable

Result: 2YF

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

Unique (cost=34,548.39..34,818.24 rows=26,985 width=112) (actual rows= loops=)

2. 0.000 0.000 ↓ 0.0

Sort (cost=34,548.39..34,615.85 rows=26,985 width=112) (actual rows= loops=)

  • Sort Key: shiftoccurrence.start_date, shiftoccurrence.end_date, s.shift_uuid, (lower(s.valid_range)) DESC
3. 0.000 0.000 ↓ 0.0

Nested Loop (cost=1,000.71..32,562.31 rows=26,985 width=112) (actual rows= loops=)

4. 0.000 0.000 ↓ 0.0

Gather (cost=1,000.28..31,068.50 rows=504 width=64) (actual rows= loops=)

  • Workers Planned: 3
5. 0.000 0.000 ↓ 0.0

Nested Loop (cost=0.28..30,018.10 rows=163 width=64) (actual rows= loops=)

6. 0.000 0.000 ↓ 0.0

Parallel Seq Scan on shift_occurrence_org_part_41 shiftoccurrence (cost=0.00..28,197.38 rows=4,666 width=48) (actual rows= loops=)

  • Filter: ((organization_uuid = '8d3a618b-96c0-4af3-a2fb-d10df4e12b6e'::uuid) AND ((tstzrange((start_date)::timestamp with time zone, (end_date)::timestamp with time zone, '[)'::text) @> '2020-02-29 16:00:00-08'::timestamp with time zone) OR (tstzrange((start_date)::timestamp with time zone, (end_date)::timestamp with time zone, '[)'::text) @> '2020-03-11 16:59:59-07'::timestamp with time zone) OR (tstzrange((start_date)::timestamp with time zone, (end_date)::timestamp with time zone, '[)'::text) <@ '["2020-02-29 16:00:00-08","2020-03-11 16:59:59-07"]'::tstzrange)))
7. 0.000 0.000 ↓ 0.0

Index Scan using groups_org_part_72_group_uuid_idx on groups_org_part_72 g (cost=0.28..0.38 rows=1 width=51) (actual rows= loops=)

  • Index Cond: (group_uuid = shiftoccurrence.group_uuid)
  • Filter: ((is_visible IS TRUE) AND (organization_uuid = '8d3a618b-96c0-4af3-a2fb-d10df4e12b6e'::uuid) AND (valid_range @> (shiftoccurrence.end_date)::timestamp with time zone))
8. 0.000 0.000 ↓ 0.0

Index Scan using shifts_org_part_default_pkey on shifts_org_part_default s (cost=0.43..2.69 rows=1 width=69) (actual rows= loops=)

  • Index Cond: ((organization_uuid = '8d3a618b-96c0-4af3-a2fb-d10df4e12b6e'::uuid) AND (revision_uuid = shiftoccurrence.shift_revision_uuid))
  • Filter: (is_visible IS TRUE)