explain.depesz.com

PostgreSQL's explain analyze made readable

Result: oxyU

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

Nested Loop Left Join (cost=5,339.94..6,943.68 rows=1 width=4,710) (actual rows= loops=)

  • Join Filter: (p0_.id = no.project_id)
2. 0.000 0.000 ↓ 0.0

Nested Loop Left Join (cost=5.15..976.91 rows=1 width=4,084) (actual rows= loops=)

3. 0.000 0.000 ↓ 0.0

Nested Loop Left Join (cost=4.87..968.61 rows=1 width=3,642) (actual rows= loops=)

4. 0.000 0.000 ↓ 0.0

Nested Loop Left Join (cost=0.57..956.48 rows=1 width=3,176) (actual rows= loops=)

  • Join Filter: (p0_.company_id = c1_.id)
5. 0.000 0.000 ↓ 0.0

Nested Loop Left Join (cost=0.57..954.81 rows=1 width=2,280) (actual rows= loops=)

6. 0.000 0.000 ↓ 0.0

Seq Scan on project p0_ (cost=0.00..946.11 rows=1 width=1,902) (actual rows= loops=)

  • Filter: ((secure_id)::text = 'y7FXQytt'::text)
7. 0.000 0.000 ↓ 0.0

Nested Loop Left Join (cost=0.57..8.69 rows=1 width=378) (actual rows= loops=)

8. 0.000 0.000 ↓ 0.0

Index Scan using project_pkey on project p (cost=0.29..8.30 rows=1 width=12) (actual rows= loops=)

  • Index Cond: (p0_.id = id)
9. 0.000 0.000 ↓ 0.0

Index Scan using endpoint_project_export_status_b423e462d8dae182f829545d6bd17a70 on endpoint_project_export_status epes (cost=0.28..0.37 rows=1 width=381) (actual rows= loops=)

  • Index Cond: (p.id = project_id)
  • Filter: (endpoint_id = p.endpoint_id)
10. 0.000 0.000 ↓ 0.0

Seq Scan on company c1_ (cost=0.00..1.30 rows=30 width=896) (actual rows= loops=)

11. 0.000 0.000 ↓ 0.0

Bitmap Heap Scan on project_cover p2_ (cost=4.30..12.11 rows=1 width=466) (actual rows= loops=)

  • Recheck Cond: (p0_.id = project_id)
  • Filter: is_active_flag
12. 0.000 0.000 ↓ 0.0

Bitmap Index Scan on project_cover_b423e462d8dae182f829545d6bd17a70 (cost=0.00..4.30 rows=2 width=0) (actual rows= loops=)

  • Index Cond: (p0_.id = project_id)
13. 0.000 0.000 ↓ 0.0

Index Scan using project_banner_b423e462d8dae182f829545d6bd17a70 on project_banner p3_ (cost=0.28..8.29 rows=1 width=442) (actual rows= loops=)

  • Index Cond: (p0_.id = project_id)
  • Filter: is_active_flag
14. 0.000 0.000 ↓ 0.0

CTE Scan on normalized_orders no (cost=5,334.79..5,963.62 rows=140 width=626) (actual rows= loops=)

  • Filter: ("order" = 1)
15.          

CTE normalized_orders

16. 0.000 0.000 ↓ 0.0

WindowAgg (cost=4,775.83..5,334.79 rows=27,948 width=64) (actual rows= loops=)

17. 0.000 0.000 ↓ 0.0

Sort (cost=4,775.83..4,845.70 rows=27,948 width=64) (actual rows= loops=)

  • Sort Key: d.project_id, d.order_number
18. 0.000 0.000 ↓ 0.0

Hash Join (cost=1,075.00..2,711.81 rows=27,948 width=64) (actual rows= loops=)

  • Hash Cond: (d.project_id = p_1.id)
19. 0.000 0.000 ↓ 0.0

Seq Scan on document d (cost=0.00..1,252.52 rows=27,948 width=56) (actual rows= loops=)

  • Filter: (deleted_at IS NULL)
20. 0.000 0.000 ↓ 0.0

Hash (cost=913.89..913.89 rows=12,889 width=8) (actual rows= loops=)

21. 0.000 0.000 ↓ 0.0

Seq Scan on project p_1 (cost=0.00..913.89 rows=12,889 width=8) (actual rows= loops=)