explain.depesz.com

PostgreSQL's explain analyze made readable

Result: apbL

Settings
# exclusive inclusive rows x rows loops node
1. 26,674.119 26,674.119 ↓ 3.5 67,842 1

CTE Scan on subscription_estimation (cost=312,105,266.34..312,105,649.12 rows=19,139 width=84) (actual time=26,325.635..26,674.119 rows=67,842 loops=1)

2.          

CTE skutoexclude

3. 0.013 0.013 ↓ 0.0 0 1

Seq Scan on orders_ordersettings (cost=0.00..12.66 rows=1,000 width=29) (actual time=0.013..0.013 rows=0 loops=1)

  • Filter: ((key)::text = 'order_milk_estimation_sku_ids_to_include'::text)
  • Rows Removed by Filter: 53
4.          

CTE skutoinclude

5. 0.010 0.010 ↓ 0.0 0 1

Seq Scan on orders_ordersettings orders_ordersettings_1 (cost=0.00..12.66 rows=1,000 width=29) (actual time=0.010..0.010 rows=0 loops=1)

  • Filter: ((key)::text = 'order_milk_estimation_sku_ids_to_exclude'::text)
  • Rows Removed by Filter: 53
6.          

CTE bizcategorytoexclude

7. 0.049 0.049 ↑ 1,000.0 1 1

Seq Scan on orders_ordersettings orders_ordersettings_2 (cost=0.00..12.66 rows=1,000 width=29) (actual time=0.028..0.049 rows=1 loops=1)

  • Filter: ((key)::text = 'order_milk_estimation_biz_category_ids_to_include'::text)
  • Rows Removed by Filter: 52
8.          

CTE milkskuids

9. 0.128 6.075 ↑ 37.5 171 1

HashSetOp Except (cost=484.98..597.58 rows=6,408 width=4) (actual time=6.024..6.075 rows=171 loops=1)

10. 0.051 5.947 ↑ 43.3 171 1

Append (cost=484.98..579.06 rows=7,408 width=4) (actual time=5.756..5.947 rows=171 loops=1)

11. 0.082 5.885 ↑ 37.5 171 1

Result (cost=484.98..549.06 rows=6,408 width=4) (actual time=5.756..5.885 rows=171 loops=1)

12. 0.149 5.803 ↑ 37.5 171 1

HashAggregate (cost=484.98..549.06 rows=6,408 width=4) (actual time=5.754..5.803 rows=171 loops=1)

  • Group Key: sf.sku_id
13. 0.062 5.654 ↑ 37.5 171 1

Append (cost=27.00..468.96 rows=6,408 width=4) (actual time=0.294..5.654 rows=171 loops=1)

14. 2.689 5.578 ↑ 31.6 171 1

Hash Join (cost=27.00..384.88 rows=5,408 width=4) (actual time=0.294..5.578 rows=171 loops=1)

  • Hash Cond: (sf.biz_category_l1_id = bizcategorytoexclude.biz_category_id)
15. 2.827 2.827 ↓ 1.0 10,834 1

Seq Scan on sku_fact sf (cost=0.00..209.16 rows=10,816 width=8) (actual time=0.007..2.827 rows=10,834 loops=1)

16. 0.003 0.062 ↑ 200.0 1 1

Hash (cost=24.50..24.50 rows=200 width=4) (actual time=0.062..0.062 rows=1 loops=1)

  • Buckets: 1,024 Batches: 1 Memory Usage: 9kB
17. 0.008 0.059 ↑ 200.0 1 1

HashAggregate (cost=22.50..24.50 rows=200 width=4) (actual time=0.058..0.059 rows=1 loops=1)

  • Group Key: bizcategorytoexclude.biz_category_id
18. 0.051 0.051 ↑ 1,000.0 1 1

CTE Scan on bizcategorytoexclude (cost=0.00..20.00 rows=1,000 width=4) (actual time=0.030..0.051 rows=1 loops=1)

19. 0.014 0.014 ↓ 0.0 0 1

CTE Scan on skutoexclude (cost=0.00..20.00 rows=1,000 width=4) (actual time=0.014..0.014 rows=0 loops=1)

20. 0.001 0.011 ↓ 0.0 0 1

Subquery Scan on *SELECT* 3 (cost=0.00..30.00 rows=1,000 width=4) (actual time=0.011..0.011 rows=0 loops=1)

21. 0.010 0.010 ↓ 0.0 0 1

CTE Scan on skutoinclude (cost=0.00..20.00 rows=1,000 width=4) (actual time=0.010..0.010 rows=0 loops=1)

22.          

CTE daterange

23. 0.191 0.191 ↓ 2.3 7 1

CTE Scan on seq (cost=5.02..5.25 rows=3 width=4) (actual time=0.165..0.191 rows=7 loops=1)

  • Filter: (num > 0)
  • Rows Removed by Filter: 1
24.          

CTE digit

25. 0.007 0.021 ↑ 1.0 10 1

Append (cost=0.00..0.20 rows=10 width=4) (actual time=0.002..0.021 rows=10 loops=1)

26. 0.001 0.001 ↑ 1.0 1 1

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

27. 0.001 0.001 ↑ 1.0 1 1

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

28. 0.002 0.002 ↑ 1.0 1 1

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

29. 0.001 0.001 ↑ 1.0 1 1

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

30. 0.001 0.001 ↑ 1.0 1 1

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

31. 0.001 0.001 ↑ 1.0 1 1

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

32. 0.002 0.002 ↑ 1.0 1 1

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

33. 0.001 0.001 ↑ 1.0 1 1

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

34. 0.002 0.002 ↑ 1.0 1 1

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

35. 0.002 0.002 ↑ 1.0 1 1

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

36.          

CTE seq

37. 0.005 0.153 ↑ 1.0 8 1

Limit (cost=4.80..4.82 rows=8 width=8) (actual time=0.146..0.153 rows=8 loops=1)

38. 0.032 0.148 ↑ 12.5 8 1

Sort (cost=4.80..5.05 rows=100 width=8) (actual time=0.145..0.148 rows=8 loops=1)

  • Sort Key: ((a.d + (10 * b.d)))
  • Sort Method: top-N heapsort Memory: 25kB
39. 0.058 0.116 ↑ 1.0 100 1

Nested Loop (cost=0.00..2.80 rows=100 width=8) (actual time=0.010..0.116 rows=100 loops=1)

40. 0.008 0.008 ↑ 1.0 10 1

CTE Scan on digit a (cost=0.00..0.20 rows=10 width=4) (actual time=0.004..0.008 rows=10 loops=1)

41. 0.050 0.050 ↑ 1.0 10 10

CTE Scan on digit b (cost=0.00..0.20 rows=10 width=4) (actual time=0.000..0.005 rows=10 loops=10)

42.          

CTE customer_price_segment

43. 76.525 564.718 ↓ 67.3 159,195 1

Subquery Scan on primary_seg (cost=396,590.73..411,956.99 rows=2,364 width=8) (actual time=274.155..564.718 rows=159,195 loops=1)

  • Filter: (primary_seg.rank_order = 1)
  • Rows Removed by Filter: 22,449
44. 142.103 488.193 ↑ 2.6 181,644 1

WindowAgg (cost=396,590.73..406,046.89 rows=472,808 width=12) (actual time=274.135..488.193 rows=181,644 loops=1)

45. 203.917 346.090 ↑ 2.6 181,644 1

Sort (cost=396,590.73..397,772.75 rows=472,808 width=12) (actual time=274.126..346.090 rows=181,644 loops=1)

  • Sort Key: cust_seg.customer_id, price_seg.rank
  • Sort Method: external merge Disk: 3,896kB
46. 80.366 142.173 ↑ 2.6 181,644 1

Nested Loop (cost=0.56..343,944.96 rows=472,808 width=12) (actual time=0.042..142.173 rows=181,644 loops=1)

47. 0.019 0.019 ↑ 1.2 4 1

Seq Scan on pricing_pricingsegmentregistry price_seg (cost=0.00..1.36 rows=5 width=8) (actual time=0.013..0.019 rows=4 loops=1)

  • Filter: active
  • Rows Removed by Filter: 36
48. 61.788 61.788 ↑ 2.1 45,411 4

Index Scan using segmentation_customersegmentmapping_3e8e3332 on segmentation_customersegmentmapping cust_seg (cost=0.56..67,843.10 rows=94,562 width=8) (actual time=0.016..15.447 rows=45,411 loops=4)

  • Index Cond: (segment_id = price_seg.segment_id)
49.          

CTE subscription_fact_intermediate

50. 1,102.520 19,125.736 ↑ 5.0 115,714 1

Merge Join (cost=1,200,589.39..311,025,311.37 rows=574,163 width=58) (actual time=12,840.452..19,125.736 rows=115,714 loops=1)

  • Merge Cond: ((subscription.sku_id = hsku.sku_id) AND (address.hub_id = hsku.hub_id))
51. 2,830.496 10,877.905 ↓ 1.7 746,044 1

Sort (cost=416,339.70..417,434.76 rows=438,025 width=50) (actual time=10,547.437..10,877.905 rows=746,044 loops=1)

  • Sort Key: subscription.sku_id, address.hub_id
  • Sort Method: external merge Disk: 42,408kB
52. 558.138 8,047.409 ↓ 1.7 746,044 1

Merge Left Join (cost=352,445.43..360,322.32 rows=438,025 width=50) (actual time=6,160.594..8,047.409 rows=746,044 loops=1)

  • Merge Cond: ((subscription.sku_id = segment_discount.sku_id) AND (customer_price_segment.segment_id = segment_discount.segment_id))
53. 1,546.691 6,718.037 ↓ 1.7 732,658 1

Sort (cost=306,737.35..307,832.41 rows=438,025 width=40) (actual time=6,160.589..6,718.037 rows=732,658 loops=1)

  • Sort Key: subscription.sku_id, customer_price_segment.segment_id
  • Sort Method: external merge Disk: 40,512kB
54. 468.724 5,171.346 ↓ 1.7 732,658 1

Hash Right Join (cost=249,466.26..253,712.47 rows=438,025 width=40) (actual time=4,316.915..5,171.346 rows=732,658 loops=1)

  • Hash Cond: (customer_price_segment.customer_id = subscription.customer_id)
55. 660.247 660.247 ↓ 67.3 159,195 1

CTE Scan on customer_price_segment (cost=0.00..47.28 rows=2,364 width=8) (actual time=274.159..660.247 rows=159,195 loops=1)

56. 361.961 4,042.375 ↓ 1.7 732,658 1

Hash (cost=240,567.95..240,567.95 rows=438,025 width=36) (actual time=4,042.375..4,042.375 rows=732,658 loops=1)

  • Buckets: 65,536 Batches: 16 Memory Usage: 3,756kB
57. 942.789 3,680.414 ↓ 1.7 732,658 1

Hash Join (cost=169,562.83..240,567.95 rows=438,025 width=36) (actual time=2,039.661..3,680.414 rows=732,658 loops=1)

  • Hash Cond: (subscription.address_id = address.id)
58. 703.528 782.234 ↓ 1.0 732,669 1

Bitmap Heap Scan on subscriptions_subscription subscription (cost=23,293.35..68,600.97 rows=730,650 width=32) (actual time=83.850..782.234 rows=732,669 loops=1)

  • Recheck Cond: (cancel_date_time IS NULL)
  • Filter: (start_date <= (('now'::cstring)::date + '7 days'::interval))
  • Rows Removed by Filter: 72
  • Heap Blocks: exact=28,102
59. 78.706 78.706 ↑ 1.0 734,436 1

Bitmap Index Scan on index_customer_cancel_date_subscription (cost=0.00..23,110.69 rows=734,881 width=0) (actual time=78.706..78.706 rows=734,436 loops=1)

  • Index Cond: (cancel_date_time IS NULL)
60. 668.125 1,955.391 ↑ 1.0 1,961,043 1

Hash (cost=114,040.40..114,040.40 rows=1,964,406 width=8) (actual time=1,955.391..1,955.391 rows=1,961,043 loops=1)

  • Buckets: 131,072 Batches: 32 Memory Usage: 3,418kB
61. 1,287.266 1,287.266 ↑ 1.0 1,961,043 1

Seq Scan on address_v3_addressv3cached address (cost=0.00..114,040.40 rows=1,964,406 width=8) (actual time=0.006..1,287.266 rows=1,961,043 loops=1)

  • Filter: active
  • Rows Removed by Filter: 1,313,458
62. 139.526 771.234 ↓ 1.0 335,413 1

Materialize (cost=45,708.08..47,331.47 rows=324,677 width=22) (actual time=455.474..771.234 rows=335,413 loops=1)

63. 502.334 631.708 ↓ 1.0 324,798 1

Sort (cost=45,708.08..46,519.77 rows=324,677 width=22) (actual time=455.471..631.708 rows=324,798 loops=1)

  • Sort Key: segment_discount.sku_id, segment_discount.segment_id
  • Sort Method: external merge Disk: 10,168kB
64. 129.374 129.374 ↓ 1.0 324,798 1

Seq Scan on pricing_segmentskupricing segment_discount (cost=0.00..9,325.60 rows=324,677 width=22) (actual time=0.008..129.374 rows=324,798 loops=1)

  • Filter: (NOT deleted)
  • Rows Removed by Filter: 167,240
65. 383.618 3,211.035 ↓ 1.1 940,959 1

Materialize (cost=783,751.71..788,083.85 rows=866,428 width=20) (actual time=2,292.870..3,211.035 rows=940,959 loops=1)

66. 1,379.523 2,827.417 ↑ 1.0 834,757 1

Sort (cost=783,751.71..785,917.78 rows=866,428 width=20) (actual time=2,292.865..2,827.417 rows=834,757 loops=1)

  • Sort Key: hsku.sku_id, hsku.hub_id
  • Sort Method: external merge Disk: 21,088kB
67. 585.542 1,447.894 ↑ 1.0 853,821 1

Hash Join (cost=660.11..680,531.96 rows=866,428 width=20) (actual time=13.739..1,447.894 rows=853,821 loops=1)

  • Hash Cond: (hsku.sku_id = products_sku.id)
68. 848.647 848.647 ↑ 2.0 867,186 1

Seq Scan on products_hubsku hsku (cost=0.00..664,709.96 rows=1,732,696 width=16) (actual time=0.010..848.647 rows=867,186 loops=1)

69. 3.160 13.705 ↓ 2.0 10,663 1

Hash (cost=592.44..592.44 rows=5,414 width=4) (actual time=13.705..13.705 rows=10,663 loops=1)

  • Buckets: 16,384 (originally 8192) Batches: 1 (originally 1) Memory Usage: 503kB
70. 4.269 10.545 ↓ 2.0 10,663 1

Index Only Scan using products_sku_pkey on products_sku (cost=146.97..592.44 rows=5,414 width=4) (actual time=6.359..10.545 rows=10,663 loops=1)

  • Filter: (NOT (hashed SubPlan 11))
  • Rows Removed by Filter: 171
  • Heap Fetches: 58
71.          

SubPlan (for Index Only Scan)

72. 0.117 6.276 ↑ 1.2 171 1

HashAggregate (cost=144.18..146.18 rows=200 width=4) (actual time=6.220..6.276 rows=171 loops=1)

  • Group Key: milkskuids.sku_id
73. 6.159 6.159 ↑ 37.5 171 1

CTE Scan on milkskuids (cost=0.00..128.16 rows=6,408 width=4) (actual time=6.027..6.159 rows=171 loops=1)

74.          

SubPlan (for Merge Join)

75. 578.570 2,545.708 ↑ 1.0 1 115,714

Aggregate (cost=269.76..269.77 rows=1 width=4) (actual time=0.022..0.022 rows=1 loops=115,714)

76. 1,967.138 1,967.138 ↑ 6.9 11 115,714

Index Scan using subscriptions_balancesummary_ef42673f on subscriptions_balancesummary summary (cost=0.44..269.57 rows=76 width=4) (actual time=0.005..0.017 rows=11 loops=115,714)

  • Index Cond: (subscription_id = subscription.id)
77. 578.570 1,388.568 ↑ 1.0 1 115,714

Aggregate (cost=269.76..269.77 rows=1 width=3) (actual time=0.012..0.012 rows=1 loops=115,714)

78. 809.998 809.998 ↑ 6.9 11 115,714

Index Scan using subscriptions_balancesummary_ef42673f on subscriptions_balancesummary summary_1 (cost=0.44..269.57 rows=76 width=3) (actual time=0.002..0.007 rows=11 loops=115,714)

  • Index Cond: (subscription_id = subscription.id)
79.          

CTE subscription_fact

80. 462.943 25,051.617 ↓ 4.0 691,068 1

Unique (cost=292,047.16..308,315.11 rows=172,249 width=170) (actual time=24,204.392..25,051.617 rows=691,068 loops=1)

81. 2,795.823 24,588.674 ↓ 1.4 783,773 1

Sort (cost=292,047.16..293,402.82 rows=542,265 width=170) (actual time=24,204.391..24,588.674 rows=783,773 loops=1)

  • Sort Key: sfi.subscription_id, sfi.quantity, sfi.address_id, sfi.customer_id, sfi.start_date, sfi.sku_id, sfi.subscription_schedule, (floor((sfi.v1_remaining_quantity + CASE WHEN (sfi.selling_price = '0'::numeric) THEN '0'::numeric ELSE (sfi.v2_remaining_balance / sfi.selling_price) END))), sfi.hub_id, sfi.selling_price, dr.future_date
  • Sort Method: external merge Disk: 54,312kB
82. 1,309.432 21,792.851 ↓ 1.4 783,773 1

Hash Anti Join (cost=84,293.88..194,063.61 rows=542,265 width=170) (actual time=13,331.329..21,792.851 rows=783,773 loops=1)

  • Hash Cond: (sfi.customer_id = vacation.customer_id)
  • Join Filter: ((dr.future_date >= vacation.start_date) AND (dr.future_date <= COALESCE((vacation.end_date)::timestamp without time zone, (('now'::cstring)::date + '10 days'::interval))))
  • Rows Removed by Join Filter: 526,963
83. 495.588 19,993.849 ↓ 1.4 809,751 1

Nested Loop (cost=0.00..50,239.29 rows=574,163 width=170) (actual time=12,840.628..19,993.849 rows=809,751 loops=1)

  • Join Filter: (sfi.start_date <= dr.future_date)
  • Rows Removed by Join Filter: 247
84. 19,266.833 19,266.833 ↑ 5.0 115,714 1

CTE Scan on subscription_fact_intermediate sfi (cost=0.00..11,483.26 rows=574,163 width=166) (actual time=12,840.455..19,266.833 rows=115,714 loops=1)

85. 231.428 231.428 ↓ 2.3 7 115,714

CTE Scan on daterange dr (cost=0.00..0.06 rows=3 width=4) (actual time=0.000..0.002 rows=7 loops=115,714)

86. 192.724 489.570 ↓ 1.0 538,536 1

Hash (cost=75,184.69..75,184.69 rows=524,015 width=12) (actual time=489.570..489.570 rows=538,536 loops=1)

  • Buckets: 131,072 Batches: 8 Memory Usage: 3,922kB
87. 237.122 296.846 ↓ 1.0 538,536 1

Bitmap Heap Scan on vacation_vacation vacation (cost=24,261.54..75,184.69 rows=524,015 width=12) (actual time=65.999..296.846 rows=538,536 loops=1)

  • Recheck Cond: (cancel_date IS NULL)
  • Heap Blocks: exact=33,398
88. 59.724 59.724 ↓ 1.0 541,831 1

Bitmap Index Scan on index_together_customer_id_cancel_date (cost=0.00..24,130.54 rows=524,015 width=0) (actual time=59.724..59.724 rows=541,831 loops=1)

  • Index Cond: (cancel_date IS NULL)
89.          

CTE subscription_estimation

90. 72.759 26,622.405 ↓ 3.5 67,842 1

Subquery Scan on innerquery_4 (cost=355,405.71..359,042.06 rows=19,139 width=130) (actual time=26,325.632..26,622.405 rows=67,842 loops=1)

  • Filter: (LEAST(innerquery_4.quantity, (innerquery_4.remaining_quantity_today - COALESCE(innerquery_4.cumm_qty_lag, '0'::numeric))) > '0'::numeric)
  • Rows Removed by Filter: 9,582
91. 77.989 26,549.646 ↓ 1.3 77,424 1

WindowAgg (cost=355,405.71..358,132.97 rows=57,416 width=130) (actual time=26,325.619..26,549.646 rows=77,424 loops=1)

92. 34.191 26,471.657 ↓ 1.3 77,424 1

Subquery Scan on innerquery_2 (cost=355,405.71..357,128.19 rows=57,416 width=130) (actual time=26,325.584..26,471.657 rows=77,424 loops=1)

93. 87.575 26,437.466 ↓ 1.3 77,424 1

WindowAgg (cost=355,405.71..356,554.03 rows=57,416 width=98) (actual time=26,325.583..26,437.466 rows=77,424 loops=1)

94. 84.811 26,349.891 ↓ 1.3 77,424 1

Sort (cost=355,405.71..355,549.25 rows=57,416 width=98) (actual time=26,325.569..26,349.891 rows=77,424 loops=1)

  • Sort Key: innerquery_1.subscription_id, innerquery_1.future_date
  • Sort Method: external sort Disk: 3,176kB
95. 32.903 26,265.080 ↓ 1.3 77,424 1

Subquery Scan on innerquery_1 (cost=345,858.20..347,724.22 rows=57,416 width=98) (actual time=26,157.878..26,265.080 rows=77,424 loops=1)

96. 51.175 26,232.177 ↓ 1.3 77,424 1

Group (cost=345,858.20..347,150.06 rows=57,416 width=69) (actual time=26,157.878..26,232.177 rows=77,424 loops=1)

  • Group Key: subscription_fact.subscription_id, subscription_fact.address_id, subscription_fact.customer_id, subscription_fact.sku_id, ('S'::text), subscription_fact.remaining_quantity, subscription_fact.future_date, (CASE WHEN (subscription_instruction.quantity IS NOT NULL) THEN subscription_instruction.quantity ELSE subscription_fact.quantity END)
97. 126.374 26,181.002 ↓ 1.3 77,425 1

Sort (cost=345,858.20..346,001.74 rows=57,416 width=69) (actual time=26,157.876..26,181.002 rows=77,425 loops=1)

  • Sort Key: subscription_fact.subscription_id, subscription_fact.address_id, subscription_fact.customer_id, subscription_fact.sku_id, ('S'::text), subscription_fact.remaining_quantity, subscription_fact.future_date, (CASE WHEN (subscription_instruction.quantity IS NOT NULL) THEN subscription_instruction.quantity ELSE subscription_fact.quantity END)
  • Sort Method: external sort Disk: 3,248kB
98. 286.408 26,054.628 ↓ 1.3 77,425 1

Nested Loop Left Join (cost=0.43..338,964.20 rows=57,416 width=69) (actual time=24,204.503..26,054.628 rows=77,425 loops=1)

  • Filter: ((subscription_fact.subscription_schedule ~~ concat('%', date_part('isodow'::text, (subscription_fact.future_date)::timestamp without time zone), '%')) OR (subscription_instruction.quantity IS NOT NULL))
  • Rows Removed by Filter: 71,186
99. 25,470.998 25,470.998 ↓ 2.6 148,611 1

CTE Scan on subscription_fact (cost=0.00..3,875.60 rows=57,416 width=98) (actual time=24,204.465..25,470.998 rows=148,611 loops=1)

  • Filter: (remaining_quantity > '0'::numeric)
  • Rows Removed by Filter: 542,457
100. 297.222 297.222 ↓ 0.0 0 148,611

Index Scan using subscriptions_subscriptioninstruc_subscription_id_f318ecb5_uniq on subscriptions_subscriptioninstruction subscription_instruction (cost=0.43..5.82 rows=1 width=11) (actual time=0.002..0.002 rows=0 loops=148,611)

  • Index Cond: ((subscription_id = subscription_fact.subscription_id) AND (schedule_date = subscription_fact.future_date))
Planning time : 3.160 ms
Execution time : 26,733.987 ms