explain.depesz.com

PostgreSQL's explain analyze made readable

Result: gQdZ

Settings
# exclusive inclusive rows x rows loops node
1. 0.000 40,391.653 ↓ 2.0 2,564 1

Sort (cost=9,593,070.46..9,593,073.62 rows=1,266 width=293) (actual time=40,391.488..40,391.653 rows=2,564 loops=1)

  • Sort Key: deal_state.last_status_created DESC
  • Sort Method: quicksort Memory: 377kB
2.          

CTE suspicious_deal_aml_indicator

3. 0.354 0.354 ↑ 5.2 194 1

Function Scan on list_suspicious_aml_indicators list_suspicious_aml_indicators_1 (cost=0.25..10.25 rows=1,000 width=101) (actual time=0.339..0.354 rows=194 loops=1)

4.          

Initplan (forSort)

5. 22.684 84.994 ↑ 1.0 1 1

Aggregate (cost=4,875.60..4,875.61 rows=1 width=32) (actual time=84.993..84.994 rows=1 loops=1)

6. 62.310 62.310 ↑ 1.0 173,614 1

Seq Scan on deal_customer deal_customer_1 (cost=0.00..4,441.33 rows=173,708 width=4) (actual time=0.030..62.310 rows=173,614 loops=1)

  • Filter: (customer_id IS NOT NULL)
  • Rows Removed by Filter: 24825
7. 2.605 40,388.063 ↓ 2.0 2,564 1

Hash Left Join (cost=108,332.77..9,588,119.36 rows=1,266 width=293) (actual time=39,371.607..40,388.063 rows=2,564 loops=1)

  • Hash Cond: (deal_customer.customer_id = alias_81887655.customer_id)
8. 1.790 40,295.339 ↓ 2.0 2,564 1

Hash Left Join (cost=76,005.74..9,555,789.00 rows=1,266 width=278) (actual time=39,281.432..40,295.339 rows=2,564 loops=1)

  • Hash Cond: (deal_customer.customer_id = alias_103839166.customer_id)
9. 2.151 40,186.162 ↓ 2.0 2,564 1

Hash Left Join (cost=44,017.41..9,523,797.35 rows=1,266 width=246) (actual time=39,174.011..40,186.162 rows=2,564 loops=1)

  • Hash Cond: (deal.id = alias_132452736.deal_id)
10. 105.766 40,134.075 ↓ 2.0 2,564 1

Merge Left Join (cost=25,390.15..9,505,166.77 rows=1,266 width=214) (actual time=39,124.009..40,134.075 rows=2,564 loops=1)

  • Merge Cond: (deal.id = payment.deal_id)
11. 4.753 37,687.503 ↓ 2.0 2,564 1

Nested Loop Left Join (cost=25,389.72..9,385,945.08 rows=1,266 width=182) (actual time=36,679.006..37,687.503 rows=2,564 loops=1)

12. 1.049 37,100.722 ↓ 2.0 2,564 1

Nested Loop (cost=25,342.38..9,322,496.32 rows=1,266 width=185) (actual time=36,678.343..37,100.722 rows=2,564 loops=1)

13. 0.009 37,098.713 ↓ 2.0 2 1

Nested Loop Left Join (cost=25,342.38..9,322,462.00 rows=1 width=185) (actual time=36,678.331..37,098.713 rows=2 loops=1)

  • Join Filter: (aml_report_log.deal_id = deal.id)
  • Rows Removed by Join Filter: 4
14. 0.014 37,098.610 ↓ 2.0 2 1

Nested Loop (cost=25,329.72..9,322,449.26 rows=1 width=177) (actual time=36,678.235..37,098.610 rows=2 loops=1)

  • Join Filter: (deal.id = deal_state.deal_id)
15. 0.012 37,098.480 ↓ 2.0 2 1

Nested Loop Left Join (cost=25,329.29..9,322,448.53 rows=1 width=169) (actual time=36,678.201..37,098.480 rows=2 loops=1)

16. 52.593 36,678.422 ↓ 2.0 2 1

Merge Join (cost=25,320.59..9,322,426.06 rows=1 width=84) (actual time=36,678.150..36,678.422 rows=2 loops=1)

  • Merge Cond: (deal.id = deal_row.deal_id)
17. 1,041.932 1,041.932 ↓ 3.0 3 1

Index Scan using deal_pkey on deal (cost=0.43..101,515.04 rows=1 width=16) (actual time=1,041.919..1,041.932 rows=3 loops=1)

  • Filter: ((created >= '2019-01-09 01:00:00+02'::timestamp with time zone) AND (created < '2019-01-12 01:00:00+02'::timestamp with time zone) AND (agent_id = 4) AND (type = 'CUSTOMER'::text))
  • Rows Removed by Filter: 1082397
18. 674.091 35,583.897 ↑ 2.6 86,644 1

GroupAggregate (cost=25,320.17..9,218,111.71 rows=223,944 width=68) (actual time=373.475..35,583.897 rows=86,644 loops=1)

  • Group Key: deal_row.deal_id
19. 252.217 34,909.806 ↑ 1.1 200,369 1

Nested Loop Left Join (cost=25,320.17..9,211,953.25 rows=223,944 width=15) (actual time=370.784..34,909.806 rows=200,369 loops=1)

20. 241.134 3,199.656 ↑ 1.1 200,369 1

Nested Loop (cost=25,282.58..171,893.83 rows=223,944 width=19) (actual time=370.085..3,199.656 rows=200,369 loops=1)

  • Join Filter: (deal_1.id = deal_row.deal_id)
21. 215.220 1,658.862 ↓ 1.1 86,644 1

Merge Join (cost=25,282.15..95,332.24 rows=81,991 width=12) (actual time=370.038..1,658.862 rows=86,644 loops=1)

  • Merge Cond: (deal_state_1.deal_id = deal_1.id)
22. 1,211.600 1,211.600 ↑ 1.0 998,954 1

Index Scan using deal_state_pkey on deal_state deal_state_1 (cost=0.43..66,285.62 rows=1,001,230 width=8) (actual time=0.071..1,211.600 rows=998,954 loops=1)

  • Filter: (last_status_state = 'DONE'::text)
  • Rows Removed by Filter: 83446
23. 148.980 232.042 ↓ 1.0 91,382 1

Sort (cost=25,281.70..25,503.29 rows=88,637 width=4) (actual time=127.861..232.042 rows=91,382 loops=1)

  • Sort Key: deal_1.id
  • Sort Method: external merge Disk: 1256kB
24. 69.295 83.062 ↓ 1.0 91,382 1

Bitmap Heap Scan on deal deal_1 (cost=2,043.28..17,997.68 rows=88,637 width=4) (actual time=16.552..83.062 rows=91,382 loops=1)

  • Recheck Cond: (agent_id = 4)
  • Filter: (type = 'CUSTOMER'::text)
  • Rows Removed by Filter: 1837
  • Heap Blocks: exact=14215
25. 13.767 13.767 ↑ 1.0 93,234 1

Bitmap Index Scan on deal_agent_id_office_id_index (cost=0.00..2,021.12 rows=94,493 width=0) (actual time=13.767..13.767 rows=93,234 loops=1)

  • Index Cond: (agent_id = 4)
26. 1,299.660 1,299.660 ↑ 4.5 2 86,644

Index Scan using deal_row_deal_id_idx on deal_row (cost=0.43..0.82 rows=9 width=15) (actual time=0.008..0.015 rows=2 loops=86,644)

  • Index Cond: (deal_id = deal_state_1.deal_id)
27. 400.738 31,457.933 ↓ 0.0 0 200,369

Limit (cost=37.59..40.35 rows=1 width=1) (actual time=0.157..0.157 rows=0 loops=200,369)

28. 793.559 31,057.195 ↓ 0.0 0 200,369

Hash Join (cost=37.59..40.35 rows=1 width=1) (actual time=0.155..0.155 rows=0 loops=200,369)

  • Hash Cond: (list_suspicious_aml_indicators.id = deal_aml_indicator_1.aml_indicator_id)
29. 7.427 7.917 ↑ 2.0 101 377

HashAggregate (cost=12.75..14.75 rows=200 width=4) (actual time=0.003..0.021 rows=101 loops=377)

  • Group Key: list_suspicious_aml_indicators.id
30. 0.490 0.490 ↑ 5.2 194 1

Function Scan on list_suspicious_aml_indicators (cost=0.25..10.25 rows=1,000 width=4) (actual time=0.458..0.490 rows=194 loops=1)

31. 801.476 30,255.719 ↓ 0.0 0 200,369

Hash (cost=24.83..24.83 rows=1 width=4) (actual time=0.151..0.151 rows=0 loops=200,369)

  • Buckets: 1024 Batches: 1 Memory Usage: 9kB
32. 29,454.243 29,454.243 ↓ 0.0 0 200,369

Seq Scan on deal_aml_indicator deal_aml_indicator_1 (cost=0.00..24.83 rows=1 width=4) (actual time=0.147..0.147 rows=0 loops=200,369)

  • Filter: (deal_aml_id = deal_state_1.last_deal_aml_id)
  • Rows Removed by Filter: 1282
33. 4.832 420.046 ↓ 0.0 0 2

Hash Right Join (cost=8.70..22.46 rows=1 width=89) (actual time=209.960..210.023 rows=0 loops=2)

  • Hash Cond: (list_customer_by_id.id = deal_customer.customer_id)
34. 415.106 415.106 ↓ 43.1 43,098 1

Function Scan on list_customer_by_id (cost=0.25..10.25 rows=1,000 width=68) (actual time=412.136..415.106 rows=43,098 loops=1)

35. 0.008 0.108 ↓ 0.0 0 2

Hash (cost=8.44..8.44 rows=1 width=25) (actual time=0.054..0.054 rows=0 loops=2)

  • Buckets: 1024 Batches: 1 Memory Usage: 9kB
36. 0.100 0.100 ↓ 0.0 0 2

Index Scan using deal_customer_deal_id_ndx on deal_customer (cost=0.42..8.44 rows=1 width=25) (actual time=0.049..0.050 rows=0 loops=2)

  • Index Cond: (deal_id = deal.id)
37. 0.116 0.116 ↑ 1.0 1 2

Index Scan using deal_state_pkey on deal_state (cost=0.43..0.72 rows=1 width=16) (actual time=0.058..0.058 rows=1 loops=2)

  • Index Cond: (deal_id = deal_row.deal_id)
  • Filter: (last_status_state = 'DONE'::text)
38. 0.002 0.094 ↑ 1.5 2 2

Unique (cost=12.66..12.68 rows=3 width=12) (actual time=0.046..0.047 rows=2 loops=2)

39. 0.015 0.092 ↑ 1.0 3 2

Sort (cost=12.66..12.67 rows=3 width=12) (actual time=0.045..0.046 rows=3 loops=2)

  • Sort Key: aml_report_log.deal_id DESC, aml_report_log.reported DESC
  • Sort Method: quicksort Memory: 25kB
40. 0.077 0.077 ↓ 1.7 5 1

Index Scan using aml_report_log_agent_id_reported_index on aml_report_log (cost=0.28..12.64 rows=3 width=12) (actual time=0.038..0.077 rows=5 loops=1)

  • Index Cond: (agent_id = 4)
41. 0.960 0.960 ↓ 1.0 1,282 2

Seq Scan on deal_aml_indicator (cost=0.00..21.66 rows=1,266 width=0) (actual time=0.010..0.480 rows=1,282 loops=2)

42. 5.128 582.028 ↑ 1.0 1 2,564

Limit (cost=47.34..50.10 rows=1 width=1) (actual time=0.226..0.227 rows=1 loops=2,564)

43. 30.768 576.900 ↑ 1.0 1 2,564

Hash Join (cost=47.34..50.10 rows=1 width=1) (actual time=0.224..0.225 rows=1 loops=2,564)

  • Hash Cond: (suspicious_deal_aml_indicator.id = deal_aml_indicator_2.aml_indicator_id)
44. 30.202 30.768 ↑ 3.9 51 2,564

HashAggregate (cost=22.50..24.50 rows=200 width=4) (actual time=0.001..0.012 rows=51 loops=2,564)

  • Group Key: suspicious_deal_aml_indicator.id
45. 0.566 0.566 ↑ 5.2 194 1

CTE Scan on suspicious_deal_aml_indicator (cost=0.00..20.00 rows=1,000 width=4) (actual time=0.341..0.566 rows=194 loops=1)

46. 17.948 515.364 ↓ 2.0 2 2,564

Hash (cost=24.83..24.83 rows=1 width=8) (actual time=0.201..0.201 rows=2 loops=2,564)

  • Buckets: 1024 Batches: 1 Memory Usage: 9kB
47. 497.416 497.416 ↓ 2.0 2 2,564

Seq Scan on deal_aml_indicator deal_aml_indicator_2 (cost=0.00..24.83 rows=1 width=8) (actual time=0.193..0.194 rows=2 loops=2,564)

  • Filter: (deal_aml_id = deal_state.last_deal_aml_id)
  • Rows Removed by Filter: 1280
48. 1,219.968 2,340.806 ↓ 1.0 968,582 1

GroupAggregate (cost=0.43..107,354.81 rows=948,210 width=36) (actual time=0.079..2,340.806 rows=968,582 loops=1)

  • Group Key: payment.deal_id
49. 1,120.838 1,120.838 ↓ 1.0 1,372,951 1

Index Scan using payment_deal_id_index on payment (cost=0.43..88,646.86 rows=1,371,065 width=9) (actual time=0.071..1,120.838 rows=1,372,951 loops=1)

  • Index Cond: (deal_id IS NOT NULL)
  • Filter: (type = ANY ('{CASH,CARD}'::text[]))
  • Rows Removed by Filter: 38583
50. 5.771 49.936 ↑ 1.1 17,923 1

Hash (cost=18,370.70..18,370.70 rows=20,525 width=36) (actual time=49.936..49.936 rows=17,923 loops=1)

  • Buckets: 32768 Batches: 1 Memory Usage: 1041kB
51. 2.519 44.165 ↑ 1.1 17,923 1

Subquery Scan on alias_132452736 (cost=17,908.89..18,370.70 rows=20,525 width=36) (actual time=29.877..44.165 rows=17,923 loops=1)

52. 23.736 41.646 ↑ 1.1 17,923 1

HashAggregate (cost=17,908.89..18,165.45 rows=20,525 width=36) (actual time=29.876..41.646 rows=17,923 loops=1)

  • Group Key: payment_1.deal_id
53. 17.910 17.910 ↑ 1.0 19,681 1

Index Scan using payment_type_index on payment payment_1 (cost=0.43..17,805.89 rows=20,600 width=9) (actual time=0.063..17.910 rows=19,681 loops=1)

  • Index Cond: (type = 'TRANSFER'::text)
  • Filter: (deal_id IS NOT NULL)
  • Rows Removed by Filter: 1
54. 0.001 107.387 ↓ 0.0 0 1

Hash (cost=31,988.31..31,988.31 rows=1 width=36) (actual time=107.387..107.387 rows=0 loops=1)

  • Buckets: 1024 Batches: 1 Memory Usage: 8kB
55. 0.001 107.386 ↓ 0.0 0 1

Subquery Scan on alias_103839166 (cost=31,988.28..31,988.31 rows=1 width=36) (actual time=107.386..107.386 rows=0 loops=1)

56. 0.004 107.385 ↓ 0.0 0 1

GroupAggregate (cost=31,988.28..31,988.30 rows=1 width=36) (actual time=107.385..107.385 rows=0 loops=1)

  • Group Key: "*SELECT* 1".customer_id
57. 0.014 107.381 ↓ 0.0 0 1

Sort (cost=31,988.28..31,988.28 rows=1 width=22) (actual time=107.381..107.381 rows=0 loops=1)

  • Sort Key: "*SELECT* 1".customer_id
  • Sort Method: quicksort Memory: 25kB
58. 0.022 107.367 ↓ 0.0 0 1

Hash Anti Join (cost=22,443.03..31,988.27 rows=1 width=22) (actual time=107.366..107.367 rows=0 loops=1)

  • Hash Cond: ("*SELECT* 1".deal_id = aml_report_log_1.deal_id)
59. 0.006 107.258 ↑ 2.0 1 1

Append (cost=22,430.35..31,975.58 rows=2 width=26) (actual time=66.782..107.258 rows=1 loops=1)

60. 0.002 66.780 ↑ 1.0 1 1

Subquery Scan on *SELECT* 1 (cost=22,430.35..22,430.39 rows=1 width=40) (actual time=66.779..66.780 rows=1 loops=1)

61. 0.014 66.778 ↑ 1.0 1 1

GroupAggregate (cost=22,430.35..22,430.38 rows=1 width=45) (actual time=66.778..66.778 rows=1 loops=1)

  • Group Key: payment_2.customer_id, payment_2.deal_id, payment_2.type
62. 0.021 66.764 ↑ 1.0 1 1

Sort (cost=22,430.35..22,430.36 rows=1 width=18) (actual time=66.764..66.764 rows=1 loops=1)

  • Sort Key: payment_2.customer_id, payment_2.deal_id, payment_2.type
  • Sort Method: quicksort Memory: 25kB
63. 52.178 66.743 ↑ 1.0 1 1

Bitmap Heap Scan on payment payment_2 (cost=2,913.04..22,430.34 rows=1 width=18) (actual time=66.743..66.743 rows=1 loops=1)

  • Recheck Cond: (agent_id = 4)
  • Filter: ((customer_id IS NOT NULL) AND (deal_id IS NOT NULL) AND (last_status_created >= '2019-01-09 01:00:00+02'::timestamp with time zone) AND (last_status_created < '2019-01-12 01:00:00+02'::timestamp with time zone) AND (last_status_state = 'DONE'::text))
  • Rows Removed by Filter: 134258
  • Heap Blocks: exact=3895
64. 14.565 14.565 ↑ 1.0 134,261 1

Bitmap Index Scan on payment_agent_id_office_id_index (cost=0.00..2,913.04 rows=135,015 width=0) (actual time=14.565..14.565 rows=134,261 loops=1)

  • Index Cond: (agent_id = 4)
65. 0.002 40.472 ↓ 0.0 0 1

Subquery Scan on *SELECT* 2 (cost=7,914.27..9,545.18 rows=1 width=13) (actual time=40.472..40.472 rows=0 loops=1)

66. 4.870 40.470 ↓ 0.0 0 1

Bitmap Heap Scan on payment payment_3 (cost=7,914.27..9,545.17 rows=1 width=45) (actual time=40.470..40.470 rows=0 loops=1)

  • Recheck Cond: ((deal_id IS NULL) AND (agent_id = 4) AND (customer_id IS NOT NULL))
  • Filter: ((last_status_created >= '2019-01-09 01:00:00+02'::timestamp with time zone) AND (last_status_created < '2019-01-12 01:00:00+02'::timestamp with time zone) AND (last_status_state = 'DONE'::text))
  • Rows Removed by Filter: 13725
  • Heap Blocks: exact=329
67. 0.278 35.600 ↓ 0.0 0 1

BitmapAnd (cost=7,914.27..7,914.27 rows=469 width=0) (actual time=35.600..35.600 rows=0 loops=1)

68. 4.051 4.051 ↑ 1.0 37,132 1

Bitmap Index Scan on payment_deal_id_index (cost=0.00..843.27 rows=37,713 width=0) (actual time=4.050..4.051 rows=37,132 loops=1)

  • Index Cond: (deal_id IS NULL)
69. 9.342 9.342 ↑ 1.0 134,261 1

Bitmap Index Scan on payment_agent_id_office_id_index (cost=0.00..2,913.04 rows=135,015 width=0) (actual time=9.342..9.342 rows=134,261 loops=1)

  • Index Cond: (agent_id = 4)
70. 21.929 21.929 ↑ 1.0 189,003 1

Bitmap Index Scan on payment_customer_id_index (cost=0.00..4,157.45 rows=193,203 width=0) (actual time=21.929..21.929 rows=189,003 loops=1)

  • Index Cond: (customer_id IS NOT NULL)
71. 0.007 0.087 ↓ 1.7 5 1

Hash (cost=12.64..12.64 rows=3 width=4) (actual time=0.087..0.087 rows=5 loops=1)

  • Buckets: 1024 Batches: 1 Memory Usage: 9kB
72. 0.080 0.080 ↓ 1.7 5 1

Index Scan using aml_report_log_agent_id_reported_index on aml_report_log aml_report_log_1 (cost=0.28..12.64 rows=3 width=4) (actual time=0.054..0.080 rows=5 loops=1)

  • Index Cond: (agent_id = 4)
73. 0.001 90.119 ↓ 0.0 0 1

Hash (cost=32,327.02..32,327.02 rows=1 width=36) (actual time=90.119..90.119 rows=0 loops=1)

  • Buckets: 1024 Batches: 1 Memory Usage: 8kB
74. 0.002 90.118 ↓ 0.0 0 1

Subquery Scan on alias_81887655 (cost=32,326.99..32,327.02 rows=1 width=36) (actual time=90.117..90.118 rows=0 loops=1)

75. 0.004 90.116 ↓ 0.0 0 1

GroupAggregate (cost=32,326.99..32,327.01 rows=1 width=36) (actual time=90.116..90.116 rows=0 loops=1)

  • Group Key: "*SELECT* 1_1".customer_id
76. 0.008 90.112 ↓ 0.0 0 1

Sort (cost=32,326.99..32,326.99 rows=1 width=22) (actual time=90.112..90.112 rows=0 loops=1)

  • Sort Key: "*SELECT* 1_1".customer_id
  • Sort Method: quicksort Memory: 25kB
77. 0.001 90.104 ↓ 0.0 0 1

Hash Anti Join (cost=22,780.56..32,326.98 rows=1 width=22) (actual time=90.104..90.104 rows=0 loops=1)

  • Hash Cond: ("*SELECT* 1_1".deal_id = aml_report_log_2.deal_id)
78. 0.005 90.103 ↓ 0.0 0 1

Append (cost=22,767.89..32,314.29 rows=2 width=26) (actual time=90.103..90.103 rows=0 loops=1)

79. 0.001 58.826 ↓ 0.0 0 1

Subquery Scan on *SELECT* 1_1 (cost=22,767.89..22,767.93 rows=1 width=40) (actual time=58.826..58.826 rows=0 loops=1)

80. 0.002 58.825 ↓ 0.0 0 1

GroupAggregate (cost=22,767.89..22,767.92 rows=1 width=45) (actual time=58.825..58.825 rows=0 loops=1)

  • Group Key: payment_4.customer_id, payment_4.deal_id, payment_4.type
81. 0.008 58.823 ↓ 0.0 0 1

Sort (cost=22,767.89..22,767.89 rows=1 width=18) (actual time=58.823..58.823 rows=0 loops=1)

  • Sort Key: payment_4.customer_id, payment_4.deal_id, payment_4.type
  • Sort Method: quicksort Memory: 25kB
82. 49.886 58.815 ↓ 0.0 0 1

Bitmap Heap Scan on payment payment_4 (cost=2,913.04..22,767.88 rows=1 width=18) (actual time=58.815..58.815 rows=0 loops=1)

  • Recheck Cond: (agent_id = 4)
  • Filter: ((customer_id IS NOT NULL) AND (deal_id IS NOT NULL) AND (last_status_created >= '2019-01-09 01:00:00+02'::timestamp with time zone) AND (last_status_created < '2019-01-12 01:00:00+02'::timestamp with time zone) AND (type = ANY ('{CASH,CARD}'::text[])) AND (last_status_state = 'DONE'::text))
  • Rows Removed by Filter: 134259
  • Heap Blocks: exact=3895
83. 8.929 8.929 ↑ 1.0 134,261 1

Bitmap Index Scan on payment_agent_id_office_id_index (cost=0.00..2,913.04 rows=135,015 width=0) (actual time=8.929..8.929 rows=134,261 loops=1)

  • Index Cond: (agent_id = 4)
84. 0.002 31.272 ↓ 0.0 0 1

Subquery Scan on *SELECT* 2_1 (cost=7,914.27..9,546.36 rows=1 width=13) (actual time=31.272..31.272 rows=0 loops=1)

85. 4.958 31.270 ↓ 0.0 0 1

Bitmap Heap Scan on payment payment_5 (cost=7,914.27..9,546.35 rows=1 width=45) (actual time=31.270..31.270 rows=0 loops=1)

  • Recheck Cond: ((deal_id IS NULL) AND (agent_id = 4) AND (customer_id IS NOT NULL))
  • Filter: ((last_status_created >= '2019-01-09 01:00:00+02'::timestamp with time zone) AND (last_status_created < '2019-01-12 01:00:00+02'::timestamp with time zone) AND (type = ANY ('{CASH,CARD}'::text[])) AND (last_status_state = 'DONE'::text))
  • Rows Removed by Filter: 13725
  • Heap Blocks: exact=329
86. 0.268 26.312 ↓ 0.0 0 1

BitmapAnd (cost=7,914.27..7,914.27 rows=469 width=0) (actual time=26.311..26.312 rows=0 loops=1)

87. 2.359 2.359 ↑ 1.0 37,132 1

Bitmap Index Scan on payment_deal_id_index (cost=0.00..843.27 rows=37,713 width=0) (actual time=2.359..2.359 rows=37,132 loops=1)

  • Index Cond: (deal_id IS NULL)
88. 8.924 8.924 ↑ 1.0 134,261 1

Bitmap Index Scan on payment_agent_id_office_id_index (cost=0.00..2,913.04 rows=135,015 width=0) (actual time=8.924..8.924 rows=134,261 loops=1)

  • Index Cond: (agent_id = 4)
89. 14.761 14.761 ↑ 1.0 189,003 1

Bitmap Index Scan on payment_customer_id_index (cost=0.00..4,157.45 rows=193,203 width=0) (actual time=14.761..14.761 rows=189,003 loops=1)

  • Index Cond: (customer_id IS NOT NULL)
90. 0.000 0.000 ↓ 0.0 0

Hash (cost=12.64..12.64 rows=3 width=4) (never executed)

91. 0.000 0.000 ↓ 0.0 0

Index Scan using aml_report_log_agent_id_reported_index on aml_report_log aml_report_log_2 (cost=0.28..12.64 rows=3 width=4) (never executed)

  • Index Cond: (agent_id = 4)