explain.depesz.com

PostgreSQL's explain analyze made readable

Result: Vnaj

Settings
# exclusive inclusive rows x rows loops node
1. 1.199 93.487 ↓ 5.5 2,127 1

WindowAgg (cost=20,000,002,237.90..20,000,002,274.67 rows=387 width=258) (actual time=93.163..93.487 rows=2,127 loops=1)

2. 7.854 92.288 ↓ 5.5 2,127 1

GroupAggregate (cost=20,000,002,237.90..20,000,002,265.96 rows=387 width=255) (actual time=84.345..92.288 rows=2,127 loops=1)

  • Group Key: i.id, attr.birthday, attr.testing_money, attr.test, attr.date, attr.address, attr.salary, attr.col, attr.age, attr.data, attr.negative_salary
3. 1.443 84.434 ↓ 5.6 2,167 1

Sort (cost=20,000,002,237.90..20,000,002,238.87 rows=387 width=150) (actual time=84.318..84.434 rows=2,167 loops=1)

  • Sort Key: i.id DESC, attr.birthday, attr.testing_money, attr.test, attr.date, attr.address, attr.salary, attr.col, attr.age, attr.data, attr.negative_salary
  • Sort Method: quicksort Memory: 855kB
4. 33.201 82.991 ↓ 5.6 2,167 1

Nested Loop Left Join (cost=20,000,000,657.90..20,000,002,221.27 rows=387 width=150) (actual time=1.255..82.991 rows=2,167 loops=1)

  • Join Filter: (attr.sex105 @> ARRAY[sex105.id])
  • Rows Removed by Join Filter: 201233
5. 34.294 43.367 ↓ 5.5 2,141 1

Nested Loop Left Join (cost=10,000,000,657.90..10,000,001,748.05 rows=387 width=174) (actual time=1.233..43.367 rows=2,141 loops=1)

  • Join Filter: (attr.nationality21 @> ARRAY[nationality21.id])
  • Rows Removed by Join Filter: 199929
6. 0.957 2.692 ↓ 5.5 2,127 1

Hash Right Join (cost=657.90..1,274.84 rows=387 width=198) (actual time=1.219..2.692 rows=2,127 loops=1)

  • Hash Cond: (attr.bo_instance_id = i.id)
7. 0.532 0.532 ↑ 1.0 2,131 1

Index Scan using attrib_person_bo_instance_id_idx on attrib_person attr (cost=0.28..611.62 rows=2,131 width=136) (actual time=0.005..0.532 rows=2,131 loops=1)

8. 0.392 1.203 ↓ 5.5 2,127 1

Hash (cost=652.78..652.78 rows=387 width=70) (actual time=1.203..1.203 rows=2,127 loops=1)

  • Buckets: 4096 (originally 1024) Batches: 1 (originally 1) Memory Usage: 396kB
9. 0.811 0.811 ↓ 5.5 2,127 1

Index Scan using idx_bo_instance_bo_class_id on bo_instance i (cost=0.42..652.78 rows=387 width=70) (actual time=0.013..0.811 rows=2,127 loops=1)

  • Index Cond: (bo_class_id = 3)
  • Filter: (NOT is_deleted)
  • Rows Removed by Filter: 9
10. 6.369 6.381 ↓ 1.2 95 2,127

Materialize (cost=10,000,000,000.00..10,000,000,003.22 rows=81 width=13) (actual time=0.000..0.003 rows=95 loops=2,127)

11. 0.012 0.012 ↓ 1.2 95 1

Seq Scan on bo_attribute_value nationality21 (cost=10,000,000,000.00..10,000,000,002.81 rows=81 width=13) (actual time=0.005..0.012 rows=95 loops=1)

12. 6.414 6.423 ↓ 1.2 95 2,141

Materialize (cost=10,000,000,000.00..10,000,000,003.22 rows=81 width=13) (actual time=0.000..0.003 rows=95 loops=2,141)

13. 0.009 0.009 ↓ 1.2 95 1

Seq Scan on bo_attribute_value sex105 (cost=10,000,000,000.00..10,000,000,002.81 rows=81 width=13) (actual time=0.002..0.009 rows=95 loops=1)

Planning time : 0.369 ms
Execution time : 93.621 ms