explain.depesz.com

PostgreSQL's explain analyze made readable

Result: 3r6H : orig

Settings
# exclusive inclusive rows x rows loops node
1. 1.300 56.317 ↓ 8.0 3,293 1

Sort (cost=14,643.25..14,644.29 rows=414 width=44) (actual time=56.081..56.317 rows=3,293 loops=1)

  • Sort Key: d.created DESC, d.donationid DESC
  • Sort Method: quicksort Memory: 354kB
  • Buffers: shared hit=62091
2. 1.481 55.017 ↓ 8.0 3,293 1

HashAggregate (cost=14,616.98..14,621.12 rows=414 width=44) (actual time=54.500..55.017 rows=3,293 loops=1)

  • Group Key: ('donation'::text), d.donationid, d.created
  • Buffers: shared hit=62091
3.          

CTE instantfundraisingpromomatchgpsreturnedtograntaccount

4. 0.000 0.000 ↓ 0.0 0

Nested Loop (cost=6.50..4,506.15 rows=57 width=4) (never executed)

  • Join Filter: (accountcredit.donorid <> dcproposal_1.createduserid)
5. 0.000 0.000 ↓ 0.0 0

Nested Loop (cost=6.07..4,383.33 rows=230 width=12) (never executed)

6. 0.000 0.000 ↓ 0.0 0

Nested Loop (cost=5.63..564.40 rows=43 width=12) (never executed)

7. 0.000 0.000 ↓ 0.0 0

Nested Loop (cost=5.20..538.07 rows=43 width=12) (never executed)

8. 0.000 0.000 ↓ 0.0 0

Bitmap Heap Scan on giftpurchase giftpurchase_3 (cost=4.76..174.07 rows=43 width=12) (never executed)

  • Recheck Cond: (purchasedonorid = 3511331)
9. 0.000 0.000 ↓ 0.0 0

Bitmap Index Scan on giftpurchase_purchasedonorid (cost=0.00..4.75 rows=43 width=0) (never executed)

  • Index Cond: (purchasedonorid = 3511331)
10. 0.000 0.000 ↓ 0.0 0

Index Scan using giving_cart_item_pkey on giving_cart_item (cost=0.44..8.46 rows=1 width=8) (never executed)

  • Index Cond: (id = giftpurchase_3.cart_item)
11. 0.000 0.000 ↓ 0.0 0

Index Scan using pk_dcproposal on dcproposal dcproposal_1 (cost=0.43..0.60 rows=1 width=8) (never executed)

  • Index Cond: (proposalid = giving_cart_item.intended_project)
12. 0.000 0.000 ↓ 0.0 0

Index Scan using giftcode_altindex1 on giftcode giftcode_3 (cost=0.44..80.11 rows=870 width=8) (never executed)

  • Index Cond: (giftpurchaseid = giftpurchase_3.promomatchgpid)
13. 0.000 0.000 ↓ 0.0 0

Index Scan using accountcredit_giftcodeid on accountcredit (cost=0.43..0.51 rows=2 width=8) (never executed)

  • Index Cond: (giftcodeid = giftcode_3.id)
  • Filter: (credittype = 0)
14.          

CTE instantfundraisinggiftpurchaseandpromomatchids

15. 0.000 0.032 ↓ 0.0 0 1

Unique (cost=729.09..729.10 rows=2 width=4) (actual time=0.032..0.032 rows=0 loops=1)

  • Buffers: shared hit=14
16. 0.006 0.032 ↓ 0.0 0 1

Sort (cost=729.09..729.10 rows=2 width=4) (actual time=0.032..0.032 rows=0 loops=1)

  • Sort Key: giftpurchase_4.id
  • Sort Method: quicksort Memory: 25kB
  • Buffers: shared hit=14
17. 0.000 0.026 ↓ 0.0 0 1

Append (cost=5.20..729.08 rows=2 width=4) (actual time=0.026..0.026 rows=0 loops=1)

  • Buffers: shared hit=14
18. 0.000 0.016 ↓ 0.0 0 1

Nested Loop (cost=5.20..538.07 rows=1 width=4) (actual time=0.016..0.016 rows=0 loops=1)

  • Buffers: shared hit=9
19. 0.003 0.008 ↑ 21.5 2 1

Bitmap Heap Scan on giftpurchase giftpurchase_4 (cost=4.76..174.07 rows=43 width=8) (actual time=0.007..0.008 rows=2 loops=1)

  • Recheck Cond: (purchasedonorid = 3511331)
  • Heap Blocks: exact=2
  • Buffers: shared hit=5
20. 0.005 0.005 ↑ 21.5 2 1

Bitmap Index Scan on giftpurchase_purchasedonorid (cost=0.00..4.75 rows=43 width=0) (actual time=0.005..0.005 rows=2 loops=1)

  • Index Cond: (purchasedonorid = 3511331)
  • Buffers: shared hit=3
21. 0.008 0.008 ↓ 0.0 0 2

Index Scan using giving_cart_item_pkey on giving_cart_item giving_cart_item_1 (cost=0.44..8.46 rows=1 width=4) (actual time=0.004..0.004 rows=0 loops=2)

  • Index Cond: (id = giftpurchase_4.cart_item)
  • Filter: (intended_project IS NOT NULL)
  • Rows Removed by Filter: 0
  • Buffers: shared hit=4
22. 0.000 0.010 ↓ 0.0 0 1

Nested Loop (cost=5.19..190.99 rows=1 width=4) (actual time=0.010..0.010 rows=0 loops=1)

  • Buffers: shared hit=5
23. 0.003 0.010 ↓ 0.0 0 1

Bitmap Heap Scan on giftpurchase giftpurchase_5 (cost=4.75..174.06 rows=2 width=8) (actual time=0.010..0.010 rows=0 loops=1)

  • Recheck Cond: (purchasedonorid = 3511331)
  • Filter: (promomatchgpid IS NOT NULL)
  • Rows Removed by Filter: 2
  • Heap Blocks: exact=2
  • Buffers: shared hit=5
24. 0.007 0.007 ↑ 21.5 2 1

Bitmap Index Scan on giftpurchase_purchasedonorid (cost=0.00..4.75 rows=43 width=0) (actual time=0.007..0.007 rows=2 loops=1)

  • Index Cond: (purchasedonorid = 3511331)
  • Buffers: shared hit=3
25. 0.000 0.000 ↓ 0.0 0

Index Scan using giving_cart_item_pkey on giving_cart_item giving_cart_item_2 (cost=0.44..8.46 rows=1 width=4) (never executed)

  • Index Cond: (id = giftpurchase_5.cart_item)
  • Filter: (intended_project IS NOT NULL)
26. 0.252 53.536 ↓ 8.0 3,293 1

Append (cost=1,981.31..9,378.62 rows=414 width=44) (actual time=28.955..53.536 rows=3,293 loops=1)

  • Buffers: shared hit=62091
27. 0.482 29.694 ↓ 3,286.0 3,286 1

Unique (cost=1,981.31..1,981.32 rows=1 width=44) (actual time=28.954..29.694 rows=3,286 loops=1)

  • Buffers: shared hit=29540
28. 1.502 29.212 ↓ 3,286.0 3,286 1

Sort (cost=1,981.31..1,981.32 rows=1 width=44) (actual time=28.954..29.212 rows=3,286 loops=1)

  • Sort Key: d.donationid, d.created
  • Sort Method: quicksort Memory: 353kB
  • Buffers: shared hit=29540
29. 1.289 27.710 ↓ 3,286.0 3,286 1

Nested Loop Left Join (cost=92.23..1,981.30 rows=1 width=44) (actual time=0.066..27.710 rows=3,286 loops=1)

  • Filter: ((promoproposal.createduserid IS NULL) OR (promogp.purchasedonorid = 3511331))
  • Buffers: shared hit=29540
30. 1.077 26.421 ↓ 3,286.0 3,286 1

Nested Loop Left Join (cost=91.80..1,980.69 rows=1 width=20) (actual time=0.065..26.421 rows=3,286 loops=1)

  • Buffers: shared hit=29540
31. 1.061 25.344 ↓ 3,286.0 3,286 1

Nested Loop Left Join (cost=91.36..1,979.84 rows=1 width=20) (actual time=0.064..25.344 rows=3,286 loops=1)

  • Buffers: shared hit=29540
32. 0.711 24.283 ↓ 3,286.0 3,286 1

Hash Left Join (cost=90.93..1,979.37 rows=1 width=16) (actual time=0.064..24.283 rows=3,286 loops=1)

  • Hash Cond: (gpitem.intended_project = dcproposal.proposalid)
  • Filter: ((dcproposal.createduserid IS NULL) OR (giftpurchase.purchasedonorid = 3511331))
  • Buffers: shared hit=29522
33. 0.582 23.568 ↓ 7.7 3,286 1

Nested Loop Left Join (cost=2.62..1,889.45 rows=425 width=24) (actual time=0.048..23.568 rows=3,286 loops=1)

  • Buffers: shared hit=29519
34. 0.690 13.128 ↓ 26.5 3,286 1

Nested Loop Left Join (cost=0.87..1,267.42 rows=124 width=16) (actual time=0.039..13.128 rows=3,286 loops=1)

  • Buffers: shared hit=16267
35. 2.580 2.580 ↓ 26.5 3,286 1

Index Scan using dcdonation_altindex1 on dcdonation d (cost=0.43..217.45 rows=124 width=12) (actual time=0.027..2.580 rows=3,286 loops=1)

  • Index Cond: (donorid = 3511331)
  • Buffers: shared hit=3106
36. 9.858 9.858 ↑ 1.0 1 3,286

Index Scan using giving_cart_item_donation on giving_cart_item donationitem (cost=0.44..8.46 rows=1 width=8) (actual time=0.003..0.003 rows=1 loops=3,286)

  • Index Cond: (donation = d.donationid)
  • Filter: ((type)::text = 'proposal_donation'::text)
  • Buffers: shared hit=13161
37. 0.000 9.858 ↓ 0.0 0 3,286

Nested Loop Left Join (cost=1.74..5.00 rows=2 width=16) (actual time=0.003..0.003 rows=0 loops=3,286)

  • Buffers: shared hit=13252
38. 0.000 9.858 ↓ 0.0 0 3,286

Nested Loop Left Join (cost=1.30..3.31 rows=2 width=16) (actual time=0.003..0.003 rows=0 loops=3,286)

  • Buffers: shared hit=13252
39. 3.256 9.858 ↓ 0.0 0 3,286

Nested Loop Left Join (cost=0.88..2.36 rows=2 width=8) (actual time=0.003..0.003 rows=0 loops=3,286)

  • Buffers: shared hit=13228
40. 6.572 6.572 ↓ 0.0 0 3,286

Index Scan using giving_cart_item_cart on giving_cart_item redemptionitem (cost=0.44..0.77 rows=2 width=8) (actual time=0.002..0.002 rows=0 loops=3,286)

  • Index Cond: (cart = donationitem.cart)
  • Filter: ((type)::text = 'gc_redemption'::text)
  • Rows Removed by Filter: 1
  • Buffers: shared hit=13204
41. 0.030 0.030 ↑ 1.0 1 6

Index Scan using pk_giftcode on giftcode (cost=0.44..0.79 rows=1 width=8) (actual time=0.004..0.005 rows=1 loops=6)

  • Index Cond: (id = redemptionitem.gift_code)
  • Buffers: shared hit=24
42. 0.024 0.024 ↑ 1.0 1 6

Index Scan using pk_giftpurchase on giftpurchase (cost=0.43..0.46 rows=1 width=12) (actual time=0.004..0.004 rows=1 loops=6)

  • Index Cond: (id = giftcode.giftpurchaseid)
  • Buffers: shared hit=24
43. 0.000 0.000 ↓ 0.0 0 6

Index Scan using giving_cart_item_pkey on giving_cart_item gpitem (cost=0.44..0.83 rows=1 width=8) (actual time=0.000..0.000 rows=0 loops=6)

  • Index Cond: (id = giftpurchase.cart_item)
44. 0.000 0.004 ↓ 0.0 0 1

Hash (cost=88.05..88.05 rows=21 width=8) (actual time=0.004..0.004 rows=0 loops=1)

  • Buckets: 1024 Batches: 1 Memory Usage: 8kB
  • Buffers: shared hit=3
45. 0.004 0.004 ↓ 0.0 0 1

Index Scan using dcproposal_createduserid on dcproposal (cost=0.43..88.05 rows=21 width=8) (actual time=0.004..0.004 rows=0 loops=1)

  • Index Cond: (createduserid = 3511331)
  • Buffers: shared hit=3
46. 0.000 0.000 ↓ 0.0 0 3,286

Index Scan using uix_giftpurchase_promomatchgpid on giftpurchase promogp (cost=0.43..0.46 rows=1 width=12) (actual time=0.000..0.000 rows=0 loops=3,286)

  • Index Cond: (promomatchgpid = giftcode.giftpurchaseid)
  • Buffers: shared hit=18
47. 0.000 0.000 ↓ 0.0 0 3,286

Index Scan using giving_cart_item_pkey on giving_cart_item promoitem (cost=0.44..0.83 rows=1 width=8) (actual time=0.000..0.000 rows=0 loops=3,286)

  • Index Cond: (id = promogp.cart_item)
48. 0.000 0.000 ↓ 0.0 0 3,286

Index Scan using pk_dcproposal on dcproposal promoproposal (cost=0.43..0.60 rows=1 width=8) (actual time=0.000..0.000 rows=0 loops=3,286)

  • Index Cond: (promoitem.intended_project = proposalid)
  • Filter: (createduserid = 3511331)
49. 0.002 0.117 ↑ 32.2 6 1

Unique (cost=2,382.82..2,384.26 rows=193 width=44) (actual time=0.115..0.117 rows=6 loops=1)

  • Buffers: shared hit=46
50. 0.011 0.115 ↑ 32.2 6 1

Sort (cost=2,382.82..2,383.30 rows=193 width=44) (actual time=0.114..0.115 rows=6 loops=1)

  • Sort Key: donationitem_1.donation, donationitem_1.create_date
  • Sort Method: quicksort Memory: 25kB
  • Buffers: shared hit=46
51. 0.004 0.104 ↑ 32.2 6 1

Nested Loop (cost=6.11..2,375.49 rows=193 width=44) (actual time=0.084..0.104 rows=6 loops=1)

  • Buffers: shared hit=46
52. 0.001 0.086 ↑ 9.0 2 1

Nested Loop (cost=5.68..2,355.47 rows=18 width=4) (actual time=0.075..0.086 rows=2 loops=1)

  • Buffers: shared hit=35
53. 0.002 0.069 ↑ 53.5 2 1

Nested Loop (cost=5.24..1,960.82 rows=107 width=4) (actual time=0.064..0.069 rows=2 loops=1)

  • Buffers: shared hit=27
54. 0.016 0.059 ↑ 10.0 2 1

Bitmap Heap Scan on giftpurchase giftpurchase_1 (cost=4.80..174.22 rows=20 width=4) (actual time=0.058..0.059 rows=2 loops=1)

  • Recheck Cond: (purchasedonorid = 3511331)
  • Filter: ((sponsorgiftpurchaseid IS NULL) AND (NOT (hashed SubPlan 8)))
  • Heap Blocks: exact=2
  • Buffers: shared hit=19
55. 0.010 0.010 ↑ 21.5 2 1

Bitmap Index Scan on giftpurchase_purchasedonorid (cost=0.00..4.75 rows=43 width=0) (actual time=0.010..0.010 rows=2 loops=1)

  • Index Cond: (purchasedonorid = 3511331)
  • Buffers: shared hit=3
56.          

SubPlan (for Bitmap Heap Scan)

57. 0.033 0.033 ↓ 0.0 0 1

CTE Scan on instantfundraisinggiftpurchaseandpromomatchids instantfundraisinggiftpurchaseandpromomatchids_1 (cost=0.00..0.04 rows=2 width=4) (actual time=0.033..0.033 rows=0 loops=1)

  • Buffers: shared hit=14
58. 0.008 0.008 ↑ 870.0 1 2

Index Scan using giftcode_altindex1 on giftcode giftcode_1 (cost=0.44..80.63 rows=870 width=8) (actual time=0.004..0.004 rows=1 loops=2)

  • Index Cond: (giftpurchaseid = giftpurchase_1.id)
  • Buffers: shared hit=8
59. 0.016 0.016 ↑ 30.0 1 2

Index Scan using giving_cart_item_gift_code on giving_cart_item redemptionitem_1 (cost=0.44..3.39 rows=30 width=8) (actual time=0.008..0.008 rows=1 loops=2)

  • Index Cond: (gift_code = giftcode_1.id)
  • Filter: ((type)::text = 'gc_redemption'::text)
  • Buffers: shared hit=8
60. 0.014 0.014 ↑ 2.0 3 2

Index Scan using giving_cart_item_cart on giving_cart_item donationitem_1 (cost=0.44..1.05 rows=6 width=16) (actual time=0.005..0.007 rows=3 loops=2)

  • Index Cond: (cart = redemptionitem_1.cart)
  • Filter: ((type)::text = 'proposal_donation'::text)
  • Rows Removed by Filter: 2
  • Buffers: shared hit=11
61. 0.000 0.047 ↓ 0.0 0 1

Unique (cost=2,602.52..2,604.05 rows=204 width=44) (actual time=0.047..0.047 rows=0 loops=1)

  • Buffers: shared hit=21
62. 0.006 0.047 ↓ 0.0 0 1

Sort (cost=2,602.52..2,603.03 rows=204 width=44) (actual time=0.047..0.047 rows=0 loops=1)

  • Sort Key: donationitem_2.donation, donationitem_2.create_date
  • Sort Method: quicksort Memory: 25kB
  • Buffers: shared hit=21
63. 0.001 0.041 ↓ 0.0 0 1

Nested Loop (cost=6.39..2,594.69 rows=204 width=44) (actual time=0.041..0.041 rows=0 loops=1)

  • Buffers: shared hit=21
64. 0.003 0.040 ↓ 0.0 0 1

Nested Loop (cost=5.96..2,573.56 rows=19 width=4) (actual time=0.040..0.040 rows=0 loops=1)

  • Buffers: shared hit=21
65. 0.003 0.035 ↑ 9.5 2 1

Nested Loop (cost=5.68..2,466.43 rows=19 width=8) (actual time=0.031..0.035 rows=2 loops=1)

  • Buffers: shared hit=21
66. 0.001 0.024 ↑ 56.5 2 1

Nested Loop (cost=5.24..2,049.65 rows=113 width=8) (actual time=0.021..0.024 rows=2 loops=1)

  • Buffers: shared hit=13
67. 0.013 0.019 ↑ 10.5 2 1

Bitmap Heap Scan on giftpurchase giftpurchase_2 (cost=4.80..174.22 rows=21 width=8) (actual time=0.018..0.019 rows=2 loops=1)

  • Recheck Cond: (purchasedonorid = 3511331)
  • Filter: (NOT (hashed SubPlan 7))
  • Heap Blocks: exact=2
  • Buffers: shared hit=5
68. 0.006 0.006 ↑ 21.5 2 1

Bitmap Index Scan on giftpurchase_purchasedonorid (cost=0.00..4.75 rows=43 width=0) (actual time=0.006..0.006 rows=2 loops=1)

  • Index Cond: (purchasedonorid = 3511331)
  • Buffers: shared hit=3
69.          

SubPlan (for Bitmap Heap Scan)

70. 0.000 0.000 ↓ 0.0 0 1

CTE Scan on instantfundraisinggiftpurchaseandpromomatchids (cost=0.00..0.04 rows=2 width=4) (actual time=0.000..0.000 rows=0 loops=1)

71. 0.004 0.004 ↑ 870.0 1 2

Index Scan using giftcode_altindex1 on giftcode giftcode_2 (cost=0.44..80.61 rows=870 width=8) (actual time=0.002..0.002 rows=1 loops=2)

  • Index Cond: (giftpurchaseid = giftpurchase_2.id)
  • Buffers: shared hit=8
72. 0.008 0.008 ↑ 30.0 1 2

Index Scan using giving_cart_item_gift_code on giving_cart_item redemptionitem_2 (cost=0.44..3.39 rows=30 width=8) (actual time=0.004..0.004 rows=1 loops=2)

  • Index Cond: (gift_code = giftcode_2.id)
  • Filter: ((type)::text = 'gc_redemption'::text)
  • Buffers: shared hit=8
73. 0.002 0.002 ↓ 0.0 0 2

Index Only Scan using matching_pkey on matching (cost=0.28..5.63 rows=1 width=4) (actual time=0.001..0.001 rows=0 loops=2)

  • Index Cond: (matchingid = giftpurchase_2.sponsormatchingid)
  • Heap Fetches: 0
74. 0.000 0.000 ↓ 0.0 0

Index Scan using giving_cart_item_cart on giving_cart_item donationitem_2 (cost=0.44..1.05 rows=6 width=16) (never executed)

  • Index Cond: (cart = redemptionitem_2.cart)
  • Filter: ((type)::text = 'proposal_donation'::text)
75. 0.000 0.045 ↓ 0.0 0 1

Nested Loop (cost=176.34..441.20 rows=7 width=44) (actual time=0.045..0.045 rows=0 loops=1)

  • Buffers: shared hit=17
76.          

Initplan (for Nested Loop)

77. 0.011 0.018 ↑ 1.0 1 1

Aggregate (cost=174.18..174.19 rows=1 width=32) (actual time=0.018..0.018 rows=1 loops=1)

  • Buffers: shared hit=5
78. 0.001 0.007 ↑ 21.5 2 1

Bitmap Heap Scan on giftpurchase gp_3 (cost=4.76..174.07 rows=43 width=4) (actual time=0.007..0.007 rows=2 loops=1)

  • Recheck Cond: (purchasedonorid = 3511331)
  • Heap Blocks: exact=2
  • Buffers: shared hit=5
79. 0.006 0.006 ↑ 21.5 2 1

Bitmap Index Scan on giftpurchase_purchasedonorid (cost=0.00..4.75 rows=43 width=0) (actual time=0.006..0.006 rows=2 loops=1)

  • Index Cond: (purchasedonorid = 3511331)
  • Buffers: shared hit=3
80. 0.038 0.038 ↑ 22.0 1 1

Index Scan using payment_altindex2 on payment (cost=0.44..52.57 rows=22 width=4) (actual time=0.037..0.038 rows=1 loops=1)

  • Index Cond: (giftpurchaseid = ANY ($10))
  • Filter: ((paymenttype)::text <> 'debit'::text)
  • Rows Removed by Filter: 1
  • Buffers: shared hit=13
81. 0.004 0.004 ↓ 0.0 0 1

Index Scan using pk_giftpurchase on giftpurchase gp (cost=1.71..9.74 rows=1 width=12) (actual time=0.004..0.004 rows=0 loops=1)

  • Index Cond: (id = payment.giftpurchaseid)
  • Filter: ((cart_item IS NULL) AND (credittype <> 3) AND (amount > '0'::numeric) AND (NOT (hashed SubPlan 6)))
  • Rows Removed by Filter: 1
  • Buffers: shared hit=4
82.          

SubPlan (for Index Scan)

83. 0.000 0.000 ↓ 0.0 0

CTE Scan on instantfundraisingpromomatchgpsreturnedtograntaccount instantfundraisingpromomatchgpsreturnedtograntaccount_1 (cost=0.00..1.14 rows=57 width=4) (never executed)

84. 0.000 0.032 ↓ 0.0 0 1

Nested Loop (cost=176.34..577.67 rows=1 width=44) (actual time=0.032..0.032 rows=0 loops=1)

  • Buffers: shared hit=17
85.          

Initplan (for Nested Loop)

86. 0.011 0.017 ↑ 1.0 1 1

Aggregate (cost=174.18..174.19 rows=1 width=32) (actual time=0.017..0.017 rows=1 loops=1)

  • Buffers: shared hit=5
87. 0.000 0.006 ↑ 21.5 2 1

Bitmap Heap Scan on giftpurchase gp_2 (cost=4.76..174.07 rows=43 width=4) (actual time=0.006..0.006 rows=2 loops=1)

  • Recheck Cond: (purchasedonorid = 3511331)
  • Heap Blocks: exact=2
  • Buffers: shared hit=5
88. 0.006 0.006 ↑ 21.5 2 1

Bitmap Index Scan on giftpurchase_purchasedonorid (cost=0.00..4.75 rows=43 width=0) (actual time=0.006..0.006 rows=2 loops=1)

  • Index Cond: (purchasedonorid = 3511331)
  • Buffers: shared hit=3
89. 0.027 0.027 ↑ 36.0 1 1

Index Scan using payment_altindex2 on payment payment_1 (cost=0.44..52.57 rows=36 width=4) (actual time=0.025..0.027 rows=1 loops=1)

  • Index Cond: (giftpurchaseid = ANY ($8))
  • Filter: ((paymenttype)::text = 'debit'::text)
  • Rows Removed by Filter: 1
  • Buffers: shared hit=13
90. 0.004 0.004 ↓ 0.0 0 1

Index Scan using pk_giftpurchase on giftpurchase gp_1 (cost=1.71..9.74 rows=1 width=12) (actual time=0.004..0.004 rows=0 loops=1)

  • Index Cond: (id = payment_1.giftpurchaseid)
  • Filter: ((cart_item IS NULL) AND (sponsormatchingid IS NOT NULL) AND (credittype <> 3) AND (amount > '0'::numeric) AND (NOT (hashed SubPlan 4)))
  • Rows Removed by Filter: 1
  • Buffers: shared hit=4
91.          

SubPlan (for Index Scan)

92. 0.000 0.000 ↓ 0.0 0

CTE Scan on instantfundraisingpromomatchgpsreturnedtograntaccount (cost=0.00..1.14 rows=57 width=4) (never executed)

93. 0.000 11.904 ↑ 7.0 1 1

Nested Loop (cost=0.87..692.99 rows=7 width=44) (actual time=11.754..11.904 rows=1 loops=1)

  • Buffers: shared hit=16225
94. 2.509 2.509 ↓ 51.3 3,286 1

Index Scan using giving_cart_donor on giving_cart gc (cost=0.43..116.92 rows=64 width=4) (actual time=0.010..2.509 rows=3,286 loops=1)

  • Index Cond: (donor = 3511331)
  • Buffers: shared hit=3021
95. 9.858 9.858 ↓ 0.0 0 3,286

Index Scan using giving_cart_item_cart on giving_cart_item gci (cost=0.44..8.99 rows=1 width=16) (actual time=0.003..0.003 rows=0 loops=3,286)

  • Index Cond: (cart = gc.id)
  • Filter: ((type)::text = 'gc_purchase'::text)
  • Rows Removed by Filter: 1
  • Buffers: shared hit=13204
96. 0.000 11.445 ↓ 0.0 0 1

Nested Loop (cost=0.87..692.99 rows=1 width=44) (actual time=11.445..11.445 rows=0 loops=1)

  • Buffers: shared hit=16225
97. 2.322 2.322 ↓ 51.3 3,286 1

Index Scan using giving_cart_donor on giving_cart gc_1 (cost=0.43..116.92 rows=64 width=4) (actual time=0.010..2.322 rows=3,286 loops=1)

  • Index Cond: (donor = 3511331)
  • Buffers: shared hit=3021
98. 9.858 9.858 ↓ 0.0 0 3,286

Index Scan using giving_cart_item_cart on giving_cart_item gci_1 (cost=0.44..8.99 rows=1 width=16) (actual time=0.003..0.003 rows=0 loops=3,286)

  • Index Cond: (cart = gc_1.id)
  • Filter: ((type)::text = 'account_credit_purchase'::text)
  • Rows Removed by Filter: 1
  • Buffers: shared hit=13204
Planning time : 6.512 ms
Execution time : 57.331 ms