explain.depesz.com

PostgreSQL's explain analyze made readable

Result: PVjV

Settings
# exclusive inclusive rows x rows loops node
1. 52.106 80.686 ↓ 0.0 0 1

Insert on outfit_visit_count (cost=969.17..1,603.61 rows=10,000 width=16) (actual time=80.686..80.686 rows=0 loops=1)

  • Conflict Resolution: UPDATE
  • Conflict Arbiter Indexes: udx_outfit_visit_count_id_outfit
  • Tuples Inserted: 10,000
  • Conflicting Tuples: 0
2. 8.211 28.580 ↑ 1.0 10,000 1

Subquery Scan on *SELECT* (cost=969.17..1,603.61 rows=10,000 width=16) (actual time=13.646..28.580 rows=10,000 loops=1)

3. 1.749 20.369 ↑ 1.0 10,000 1

Limit (cost=969.17..1,453.61 rows=10,000 width=12) (actual time=12.609..20.369 rows=10,000 loops=1)

4. 9.596 18.620 ↑ 3.3 30,000 1

GroupAggregate (cost=0.29..4,843.03 rows=99,966 width=12) (actual time=0.028..18.620 rows=30,000 loops=1)

  • Group Key: outfit_visit_history.id_outfit
5. 9.024 9.024 ↑ 3.3 30,005 1

Index Scan using idx_outfit_visit_history_id_outfit on outfit_visit_history (cost=0.29..3,343.35 rows=100,004 width=8) (actual time=0.024..9.024 rows=30,005 loops=1)

  • Filter: (deleted_at IS NULL)
Planning time : 1.868 ms
Execution time : 80.778 ms