explain.depesz.com

PostgreSQL's explain analyze made readable

Result: u2Id

Settings
# exclusive inclusive rows x rows loops node
1. 72.275 72.275 ↑ 1.7 92 1

Hash Left Join (cost=18,563.94..19,609.80 rows=153 width=1,146) (actual time=71.413..72.275 rows=92 loops=1)

  • Hash Cond: (asset.id = building_constructable.portfolio_asset_id)
2.          

CTE params

3. 0.001 0.001 ↑ 1.0 1 1

Result (cost=0.00..0.01 rows=1 width=36) (actual time=0.001..0.001 rows=1 loops=1)

4.          

CTE asset_details

5. 0.027 0.672 ↓ 23.0 92 1

Sort (cost=54.88..54.89 rows=4 width=16) (actual time=0.668..0.672 rows=92 loops=1)

  • Sort Key: portfolio_asset_1.main_address_id
  • Sort Method: quicksort Memory: 29kB
6.          

Initplan (for Sort)

7. 0.004 0.004 ↑ 1.0 1 1

CTE Scan on params (cost=0.00..0.02 rows=1 width=4) (actual time=0.004..0.004 rows=1 loops=1)

8. 0.001 0.001 ↑ 1.0 1 1

CTE Scan on params params_1 (cost=0.00..0.02 rows=1 width=32) (actual time=0.001..0.001 rows=1 loops=1)

9. 0.091 0.640 ↓ 23.0 92 1

Nested Loop Left Join (cost=5.00..54.80 rows=4 width=16) (actual time=0.104..0.640 rows=92 loops=1)

10. 0.098 0.273 ↓ 23.0 92 1

Hash Left Join (cost=4.57..20.99 rows=4 width=12) (actual time=0.080..0.273 rows=92 loops=1)

  • Hash Cond: (portfolio_asset_1.company_branch_id = company_branch_1.id)
  • Filter: ((company_branch_1.deleted_at IS NULL) AND ((portfolio_asset_1.company_branch_id IS NULL) OR (ARRAY[company_branch_1.user_community_id] && $2)))
11. 0.139 0.139 ↓ 4.6 92 1

Seq Scan on portfolio_asset portfolio_asset_1 (cost=0.00..16.38 rows=20 width=16) (actual time=0.026..0.139 rows=92 loops=1)

  • Filter: ((deleted_at IS NULL) AND (user_company_id = $1))
  • Rows Removed by Filter: 168
12. 0.012 0.036 ↑ 1.4 82 1

Hash (cost=3.14..3.14 rows=114 width=16) (actual time=0.036..0.036 rows=82 loops=1)

  • Buckets: 1024 Batches: 1 Memory Usage: 12kB
13. 0.024 0.024 ↑ 1.4 82 1

Seq Scan on company_branch company_branch_1 (cost=0.00..3.14 rows=114 width=16) (actual time=0.010..0.024 rows=82 loops=1)

14. 0.276 0.276 ↓ 0.0 0 92

Index Scan using gen_match_cap_address_pkey on gen_match_cap_address (cost=0.43..8.45 rows=1 width=8) (actual time=0.003..0.003 rows=0 loops=92)

  • Index Cond: (address_id = portfolio_asset_1.main_address_id)
15.          

CTE asset

16. 0.118 18.984 ↑ 1.2 92 1

Unique (cost=431.78..432.34 rows=113 width=592) (actual time=18.744..18.984 rows=92 loops=1)

17. 0.640 18.866 ↓ 11.8 1,332 1

Sort (cost=431.78..432.06 rows=113 width=592) (actual time=18.742..18.866 rows=1,332 loops=1)

  • Sort Key: portfolio_asset_2.id
  • Sort Method: quicksort Memory: 236kB
18. 1.060 18.226 ↓ 11.8 1,332 1

Hash Left Join (cost=19.32..427.92 rows=113 width=592) (actual time=0.936..18.226 rows=1,332 loops=1)

  • Hash Cond: (address_street.ref_address_street_type_id = ref_address_street_type.id)
19. 0.286 17.079 ↓ 11.8 1,332 1

Nested Loop Left Join (cost=10.57..413.51 rows=113 width=343) (actual time=0.831..17.079 rows=1,332 loops=1)

20. 0.103 15.413 ↓ 23.0 92 1

Nested Loop Left Join (cost=10.01..113.10 rows=4 width=343) (actual time=0.813..15.413 rows=92 loops=1)

21. 0.133 15.034 ↓ 23.0 92 1

Nested Loop Left Join (cost=9.72..89.99 rows=4 width=324) (actual time=0.800..15.034 rows=92 loops=1)

22. 11.174 14.533 ↓ 23.0 92 1

Nested Loop Left Join (cost=9.29..66.22 rows=4 width=185) (actual time=0.785..14.533 rows=92 loops=1)

23. 0.208 2.899 ↓ 23.0 92 1

Nested Loop Left Join (cost=8.72..31.86 rows=4 width=129) (actual time=0.768..2.899 rows=92 loops=1)

24. 0.084 0.943 ↓ 23.0 92 1

Hash Right Join (cost=0.13..16.88 rows=4 width=107) (actual time=0.726..0.943 rows=92 loops=1)

  • Hash Cond: (portfolio_asset_2.id = asset_details.id)
25. 0.148 0.148 ↑ 1.0 260 1

Seq Scan on portfolio_asset portfolio_asset_2 (cost=0.00..15.70 rows=270 width=99) (actual time=0.007..0.148 rows=260 loops=1)

26. 0.015 0.711 ↓ 23.0 92 1

Hash (cost=0.08..0.08 rows=4 width=12) (actual time=0.711..0.711 rows=92 loops=1)

  • Buckets: 1024 Batches: 1 Memory Usage: 12kB
27. 0.696 0.696 ↓ 23.0 92 1

CTE Scan on asset_details (cost=0.00..0.08 rows=4 width=12) (actual time=0.670..0.696 rows=92 loops=1)

28. 0.745 1.748 ↑ 1.0 1 92

Hash Right Join (cost=8.59..10.18 rows=1 width=26) (actual time=0.017..0.019 rows=1 loops=92)

  • Hash Cond: (ref_address_cardinal.id = address.ref_address_cardinal_id)
29. 0.267 0.267 ↑ 1.0 42 89

Seq Scan on ref_address_cardinal (cost=0.00..1.42 rows=42 width=6) (actual time=0.001..0.003 rows=42 loops=89)

30. 0.092 0.736 ↑ 1.0 1 92

Hash (cost=8.58..8.58 rows=1 width=24) (actual time=0.008..0.008 rows=1 loops=92)

  • Buckets: 1024 Batches: 1 Memory Usage: 9kB
31. 0.644 0.644 ↑ 1.0 1 92

Index Scan using address_pkey on address (cost=0.56..8.58 rows=1 width=24) (actual time=0.007..0.007 rows=1 loops=92)

  • Index Cond: (asset_details.main_address_id = id)
32. 0.460 0.460 ↑ 1.0 1 92

Index Scan using gen_building_building_id on gen_building (cost=0.56..8.58 rows=1 width=60) (actual time=0.005..0.005 rows=1 loops=92)

  • Index Cond: (asset_details.building_id = building_id)
33. 0.368 0.368 ↑ 1.0 1 92

Index Scan using address_street_pkey on address_street (cost=0.43..5.94 rows=1 width=147) (actual time=0.004..0.004 rows=1 loops=92)

  • Index Cond: (address.address_street_id = id)
34. 0.276 0.276 ↑ 1.0 1 92

Index Scan using ref_postal_city_pkey on ref_postal_city (cost=0.29..5.78 rows=1 width=27) (actual time=0.003..0.003 rows=1 loops=92)

  • Index Cond: (address_street.ref_postal_city_id = id)
35. 1.380 1.380 ↑ 2.0 14 92

Index Only Scan using gen_address_address_id on gen_address (cost=0.56..74.82 rows=28 width=4) (actual time=0.006..0.015 rows=14 loops=92)

  • Index Cond: (address_id = asset_details.main_address_id)
  • Heap Fetches: 1328
36. 0.042 0.087 ↑ 1.0 300 1

Hash (cost=5.00..5.00 rows=300 width=12) (actual time=0.087..0.087 rows=300 loops=1)

  • Buckets: 1024 Batches: 1 Memory Usage: 22kB
37. 0.045 0.045 ↑ 1.0 300 1

Seq Scan on ref_address_street_type (cost=0.00..5.00 rows=300 width=12) (actual time=0.007..0.045 rows=300 loops=1)

38.          

CTE implantation

39. 2.129 14.970 ↓ 32.5 358 1

Nested Loop Left Join (cost=5.99..379.39 rows=11 width=944) (actual time=0.268..14.970 rows=358 loops=1)

40.          

Initplan (for Nested Loop Left Join)

41. 0.002 0.002 ↑ 1.0 1 1

CTE Scan on params params_2 (cost=0.00..0.02 rows=1 width=4) (actual time=0.002..0.002 rows=1 loops=1)

42. 0.437 10.333 ↓ 32.5 358 1

Nested Loop Left Join (cost=5.68..348.68 rows=11 width=1,061) (actual time=0.209..10.333 rows=358 loops=1)

43. 0.449 9.180 ↓ 32.5 358 1

Nested Loop Left Join (cost=5.39..320.81 rows=11 width=1,045) (actual time=0.185..9.180 rows=358 loops=1)

44. 0.459 8.731 ↓ 32.5 358 1

Nested Loop Left Join (cost=5.25..319.08 rows=11 width=1,043) (actual time=0.171..8.731 rows=358 loops=1)

45. 0.542 7.914 ↓ 32.5 358 1

Nested Loop Left Join (cost=5.10..317.26 rows=11 width=1,035) (actual time=0.150..7.914 rows=358 loops=1)

46. 0.513 6.298 ↓ 32.5 358 1

Nested Loop Left Join (cost=4.67..287.06 rows=11 width=896) (actual time=0.127..6.298 rows=358 loops=1)

47. 0.496 4.353 ↓ 32.5 358 1

Nested Loop Left Join (cost=4.11..192.67 rows=11 width=884) (actual time=0.104..4.353 rows=358 loops=1)

48. 0.342 1.709 ↓ 32.5 358 1

Hash Join (cost=3.67..99.59 rows=11 width=880) (actual time=0.078..1.709 rows=358 loops=1)

  • Hash Cond: (portfolio_implantation.portfolio_asset_id = asset_1.id)
49. 1.345 1.345 ↓ 6.2 359 1

Seq Scan on portfolio_implantation (cost=0.00..95.59 rows=58 width=880) (actual time=0.036..1.345 rows=359 loops=1)

  • Filter: ((deleted_at IS NULL) AND (user_company_id = $11))
  • Rows Removed by Filter: 1611
50. 0.010 0.022 ↑ 1.2 92 1

Hash (cost=2.26..2.26 rows=113 width=4) (actual time=0.022..0.022 rows=92 loops=1)

  • Buckets: 1024 Batches: 1 Memory Usage: 12kB
51. 0.012 0.012 ↑ 1.2 92 1

CTE Scan on asset asset_1 (cost=0.00..2.26 rows=113 width=4) (actual time=0.001..0.012 rows=92 loops=1)

52. 2.148 2.148 ↑ 1.0 1 358

Index Scan using gen_establishment_search_establishment_id on gen_establishment_search (cost=0.43..8.45 rows=1 width=8) (actual time=0.006..0.006 rows=1 loops=358)

  • Index Cond: (establishment_id = portfolio_implantation.establishment_id)
53. 1.432 1.432 ↑ 1.0 1 358

Index Scan using address_pkey on address address_1 (cost=0.56..8.58 rows=1 width=16) (actual time=0.004..0.004 rows=1 loops=358)

  • Index Cond: (COALESCE(gen_establishment_search.address_id, portfolio_implantation.main_address_id) = id)
  • Filter: (deleted_at IS NULL)
54. 1.074 1.074 ↑ 1.0 1 358

Index Scan using address_street_pkey on address_street address_street_1 (cost=0.43..2.75 rows=1 width=147) (actual time=0.003..0.003 rows=1 loops=358)

  • Index Cond: (address_1.address_street_id = id)
  • Filter: (deleted_at IS NULL)
55. 0.358 0.358 ↑ 1.0 1 358

Index Scan using ref_address_street_type_pkey on ref_address_street_type ref_address_street_type_1 (cost=0.15..0.17 rows=1 width=12) (actual time=0.001..0.001 rows=1 loops=358)

  • Index Cond: (id = address_street_1.ref_address_street_type_id)
56. 0.000 0.000 ↓ 0.0 0 358

Index Scan using ref_address_cardinal_pkey on ref_address_cardinal ref_address_cardinal_1 (cost=0.14..0.16 rows=1 width=6) (actual time=0.000..0.000 rows=0 loops=358)

  • Index Cond: (id = address_1.ref_address_cardinal_id)
57. 0.716 0.716 ↑ 1.0 1 358

Index Scan using ref_postal_city_pkey on ref_postal_city ref_postal_city_1 (cost=0.29..2.53 rows=1 width=24) (actual time=0.002..0.002 rows=1 loops=358)

  • Index Cond: (address_street_1.ref_postal_city_id = id)
58. 2.506 2.506 ↑ 1.0 1 358

Index Scan using ref_postal_code_pkey on ref_postal_code (cost=0.29..2.52 rows=1 width=10) (actual time=0.007..0.007 rows=1 loops=358)

  • Index Cond: (ref_postal_city_1.ref_postal_code_id = id)
59.          

CTE list_lots

60. 0.327 1.621 ↓ 31.0 434 1

Hash Right Join (cost=79.61..151.68 rows=14 width=41) (actual time=0.817..1.621 rows=434 loops=1)

  • Hash Cond: (lot.portfolio_implantation_id = portfolio_implantation_1.id)
61. 0.508 0.508 ↓ 1.0 2,572 1

Seq Scan on portfolio_implantation_lot lot (cost=0.00..62.22 rows=2,571 width=36) (actual time=0.013..0.508 rows=2,572 loops=1)

  • Filter: (deleted_at IS NULL)
  • Rows Removed by Filter: 53
62. 0.053 0.786 ↓ 32.5 358 1

Hash (cost=79.47..79.47 rows=11 width=8) (actual time=0.786..0.786 rows=358 loops=1)

  • Buckets: 1024 Batches: 1 Memory Usage: 22kB
63. 0.000 0.733 ↓ 32.5 358 1

Nested Loop Left Join (cost=0.28..79.47 rows=11 width=8) (actual time=0.021..0.733 rows=358 loops=1)

64. 0.043 0.043 ↓ 32.5 358 1

CTE Scan on implantation (cost=0.00..0.22 rows=11 width=4) (actual time=0.001..0.043 rows=358 loops=1)

65. 0.716 0.716 ↑ 1.0 1 358

Index Scan using portfolio_implantation_pkey on portfolio_implantation portfolio_implantation_1 (cost=0.28..7.20 rows=1 width=8) (actual time=0.002..0.002 rows=1 loops=358)

  • Index Cond: (id = implantation.id)
  • Filter: (deleted_at IS NULL)
66.          

CTE grouped_lots

67. 1.057 3.865 ↓ 25.6 358 1

GroupAggregate (cost=96.68..100.99 rows=14 width=33) (actual time=2.810..3.865 rows=358 loops=1)

  • Group Key: portfolio_implantation_2.id
68. 0.182 2.808 ↓ 31.0 434 1

Sort (cost=96.68..96.72 rows=14 width=45) (actual time=2.775..2.808 rows=434 loops=1)

  • Sort Key: portfolio_implantation_2.id
  • Sort Method: quicksort Memory: 58kB
69. 0.000 2.626 ↓ 31.0 434 1

Nested Loop Left Join (cost=0.28..96.42 rows=14 width=45) (actual time=0.829..2.626 rows=434 loops=1)

70. 1.787 1.787 ↓ 31.0 434 1

CTE Scan on list_lots (cost=0.00..0.28 rows=14 width=40) (actual time=0.819..1.787 rows=434 loops=1)

71. 0.868 0.868 ↑ 1.0 1 434

Index Scan using portfolio_implantation_pkey on portfolio_implantation portfolio_implantation_2 (cost=0.28..6.87 rows=1 width=9) (actual time=0.002..0.002 rows=1 loops=434)

  • Index Cond: (id = list_lots.portfolio_implantation_id)
72.          

CTE implantation_lot_properties_unnest

73. 0.351 1.097 ↑ 3.2 431 1

HashAggregate (cost=61.15..75.15 rows=1,400 width=20) (actual time=1.003..1.097 rows=431 loops=1)

  • Group Key: list_lots_1.portfolio_asset_id, list_lots_1.portfolio_implantation_id, list_lots_1.portfolio_implantation_lot_id, ref_property_nature_id.ref_property_nature_id
74. 0.128 0.746 ↑ 1.6 862 1

Hash Left Join (cost=10.01..43.65 rows=1,400 width=20) (actual time=0.198..0.746 rows=862 loops=1)

  • Hash Cond: (ref_property_nature_id.ref_property_nature_id = ref_property_nature_i18n.id)
75. 0.000 0.449 ↑ 3.2 431 1

Nested Loop (cost=0.00..28.28 rows=1,400 width=20) (actual time=0.018..0.449 rows=431 loops=1)

76. 0.035 0.035 ↓ 31.0 434 1

CTE Scan on list_lots list_lots_1 (cost=0.00..0.28 rows=14 width=48) (actual time=0.001..0.035 rows=434 loops=1)

77. 0.434 0.434 ↑ 100.0 1 434

Function Scan on unnest ref_property_nature_id (cost=0.00..1.00 rows=100 width=4) (actual time=0.001..0.001 rows=1 loops=434)

78. 0.027 0.169 ↓ 248.0 248 1

Hash (cost=10.00..10.00 rows=1 width=4) (actual time=0.169..0.169 rows=248 loops=1)

  • Buckets: 1024 Batches: 1 Memory Usage: 17kB
79. 0.142 0.142 ↓ 248.0 248 1

Seq Scan on ref_property_nature_i18n (cost=0.00..10.00 rows=1 width=4) (actual time=0.019..0.142 rows=248 loops=1)

  • Filter: ((culture)::text = ((SubPlan 10))::text)
80.          

SubPlan (for Seq Scan)

81. 0.000 0.000 ↑ 1.0 1 248

CTE Scan on params params_3 (cost=0.00..0.02 rows=1 width=32) (actual time=0.000..0.000 rows=1 loops=248)

82.          

CTE data_implantations

83. 0.180 4.401 ↓ 32.5 358 1

Hash Right Join (cost=0.36..0.91 rows=11 width=44) (actual time=3.037..4.401 rows=358 loops=1)

  • Hash Cond: (grouped_lots.id = implantation_1.id)
84. 4.011 4.011 ↓ 25.6 358 1

CTE Scan on grouped_lots (cost=0.00..0.28 rows=14 width=20) (actual time=2.813..4.011 rows=358 loops=1)

85. 0.047 0.210 ↓ 32.5 358 1

Hash (cost=0.22..0.22 rows=11 width=13) (actual time=0.210..0.210 rows=358 loops=1)

  • Buckets: 1024 Batches: 1 Memory Usage: 25kB
86. 0.163 0.163 ↓ 32.5 358 1

CTE Scan on implantation implantation_1 (cost=0.00..0.22 rows=11 width=13) (actual time=0.003..0.163 rows=358 loops=1)

87.          

CTE implantation_grouped_by_nature

88. 0.314 18.023 ↑ 1.8 133 1

GroupAggregate (cost=183.93..223.77 rows=242 width=72) (actual time=17.708..18.023 rows=133 loops=1)

  • Group Key: implantation_2.portfolio_asset_id, lot_1.ref_property_nature_ids
89. 0.216 17.709 ↑ 3.2 431 1

Sort (cost=183.93..187.43 rows=1,400 width=53) (actual time=17.684..17.709 rows=431 loops=1)

  • Sort Key: implantation_2.portfolio_asset_id, lot_1.ref_property_nature_ids
  • Sort Method: quicksort Memory: 64kB
90. 0.105 17.493 ↑ 3.2 431 1

Hash Left Join (cost=6.97..110.77 rows=1,400 width=53) (actual time=16.261..17.493 rows=431 loops=1)

  • Hash Cond: (ref_property_nature_id_1.ref_property_nature_id = ref_property_nature_i18n_1.id)
91. 0.000 17.310 ↑ 3.2 431 1

Nested Loop (cost=0.36..100.36 rows=1,400 width=36) (actual time=16.158..17.310 rows=431 loops=1)

92. 0.285 16.900 ↓ 30.8 431 1

Hash Join (cost=0.36..72.36 rows=14 width=32) (actual time=16.140..16.900 rows=431 loops=1)

  • Hash Cond: (lot_1.portfolio_implantation_id = implantation_2.id)
93. 0.513 0.513 ↓ 1.0 2,572 1

Seq Scan on portfolio_implantation_lot lot_1 (cost=0.00..62.22 rows=2,571 width=32) (actual time=0.013..0.513 rows=2,572 loops=1)

  • Filter: (deleted_at IS NULL)
  • Rows Removed by Filter: 53
94. 0.171 16.102 ↓ 32.5 358 1

Hash (cost=0.22..0.22 rows=11 width=8) (actual time=16.102..16.102 rows=358 loops=1)

  • Buckets: 1024 Batches: 1 Memory Usage: 22kB
95. 15.931 15.931 ↓ 32.5 358 1

CTE Scan on implantation implantation_2 (cost=0.00..0.22 rows=11 width=8) (actual time=0.277..15.931 rows=358 loops=1)

96. 0.431 0.431 ↑ 100.0 1 431

Function Scan on unnest ref_property_nature_id_1 (cost=0.00..1.00 rows=100 width=4) (actual time=0.001..0.001 rows=1 loops=431)

97. 0.022 0.078 ↓ 1.0 124 1

Hash (cost=5.08..5.08 rows=123 width=21) (actual time=0.078..0.078 rows=124 loops=1)

  • Buckets: 1024 Batches: 1 Memory Usage: 15kB
98. 0.056 0.056 ↓ 1.0 124 1

Seq Scan on ref_property_nature_i18n ref_property_nature_i18n_1 (cost=0.00..5.08 rows=123 width=21) (actual time=0.020..0.056 rows=124 loops=1)

  • Filter: ((culture)::text = 'fr_FR'::text)
  • Rows Removed by Filter: 124
99.          

CTE natures

100. 0.010 19.638 ↓ 1.0 91 1

Append (cost=14.42..38.35 rows=89 width=68) (actual time=18.174..19.638 rows=91 loops=1)

101. 0.496 18.621 ↓ 1.6 35 1

GroupAggregate (cost=14.42..25.38 rows=22 width=68) (actual time=18.171..18.621 rows=35 loops=1)

  • Group Key: implantation_grouped_by_nature.portfolio_asset_id
  • Filter: ((count(DISTINCT CASE WHEN (implantation_grouped_by_nature.ref_property_nature_id <> ALL ('{96,97,6}'::integer[])) THEN implantation_grouped_by_nature.ref_property_nature_id ELSE NULL::integer END) >= 1) AND (count(DISTINCT implantation_grouped_by_nature.ref_property_nature_id) > 1))
  • Rows Removed by Filter: 56
102. 0.030 18.125 ↑ 1.8 133 1

Sort (cost=14.42..15.03 rows=242 width=48) (actual time=18.117..18.125 rows=133 loops=1)

  • Sort Key: implantation_grouped_by_nature.portfolio_asset_id
  • Sort Method: quicksort Memory: 35kB
103. 18.095 18.095 ↑ 1.8 133 1

CTE Scan on implantation_grouped_by_nature (cost=0.00..4.84 rows=242 width=48) (actual time=17.712..18.095 rows=133 loops=1)

104. 0.381 1.007 ↑ 1.2 56 1

HashAggregate (cost=8.47..11.64 rows=67 width=68) (actual time=0.976..1.007 rows=56 loops=1)

  • Group Key: implantation_grouped_by_nature_1.portfolio_asset_id
  • Filter: (count(implantation_grouped_by_nature_1.ref_property_nature_id) < 2)
  • Rows Removed by Filter: 35
105. 0.626 0.626 ↑ 1.8 133 1

CTE Scan on implantation_grouped_by_nature implantation_grouped_by_nature_1 (cost=0.00..4.84 rows=242 width=48) (actual time=0.001..0.626 rows=133 loops=1)

106.          

CTE data_by_natures_id

107. 0.187 14.437 ↑ 10.5 133 1

GroupAggregate (cost=12,019.67..12,086.17 rows=1,400 width=32) (actual time=14.249..14.437 rows=133 loops=1)

  • Group Key: asset_2.id, implantation_lot_properties_unnest.ref_property_nature_id
108. 0.271 14.250 ↑ 3.2 431 1

Sort (cost=12,019.67..12,023.17 rows=1,400 width=36) (actual time=14.223..14.250 rows=431 loops=1)

  • Sort Key: asset_2.id, implantation_lot_properties_unnest.ref_property_nature_id
  • Sort Method: quicksort Memory: 55kB
109. 0.294 13.979 ↑ 3.2 431 1

Hash Left Join (cost=5.20..11,946.51 rows=1,400 width=36) (actual time=1.142..13.979 rows=431 loops=1)

  • Hash Cond: (implantation_lot_properties_unnest.portfolio_implantation_lot_id = list_lots_2.portfolio_implantation_lot_id)
110. 6.805 13.685 ↑ 3.2 431 1

Nested Loop Left Join (cost=4.75..11,939.83 rows=1,400 width=36) (actual time=1.030..13.685 rows=431 loops=1)

  • Join Filter: (portfolio_implantation_3.id = implantation_lot_properties_unnest.portfolio_implantation_id)
  • Rows Removed by Join Filter: 106640
111. 0.139 1.708 ↑ 3.2 431 1

Nested Loop Left Join (cost=4.10..11,874.83 rows=1,400 width=24) (actual time=0.081..1.708 rows=431 loops=1)

112. 0.156 0.276 ↑ 3.2 431 1

Hash Left Join (cost=3.67..44.83 rows=1,400 width=20) (actual time=0.053..0.276 rows=431 loops=1)

  • Hash Cond: (implantation_lot_properties_unnest.portfolio_asset_id = asset_2.id)
113. 0.078 0.078 ↑ 3.2 431 1

CTE Scan on implantation_lot_properties_unnest (cost=0.00..28.00 rows=1,400 width=16) (actual time=0.001..0.078 rows=431 loops=1)

114. 0.019 0.042 ↑ 1.2 92 1

Hash (cost=2.26..2.26 rows=113 width=8) (actual time=0.042..0.042 rows=92 loops=1)

  • Buckets: 1024 Batches: 1 Memory Usage: 12kB
115. 0.023 0.023 ↑ 1.2 92 1

CTE Scan on asset asset_2 (cost=0.00..2.26 rows=113 width=8) (actual time=0.003..0.023 rows=92 loops=1)

116. 1.293 1.293 ↑ 1.0 1 431

Index Scan using building_nature_price_rent_pkey on building_nature_price_rent (cost=0.43..8.45 rows=1 width=16) (actual time=0.003..0.003 rows=1 loops=431)

  • Index Cond: ((asset_2.building_id = building_id) AND (ref_property_nature_id = implantation_lot_properties_unnest.ref_property_nature_id))
117. 4.286 5.172 ↓ 248.0 248 431

Materialize (cost=0.65..44.00 rows=1 width=20) (actual time=0.000..0.012 rows=248 loops=431)

118. 0.636 0.886 ↓ 248.0 248 1

Nested Loop (cost=0.65..43.99 rows=1 width=20) (actual time=0.184..0.886 rows=248 loops=1)

119. 0.250 0.250 ↓ 47.2 283 1

Hash Join (cost=0.37..0.75 rows=6 width=24) (actual time=0.097..0.250 rows=283 loops=1)