Guest User

Untitled

a guest
Feb 21st, 2020
43
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. Nested Loop Left Join  (cost=1238.01..14878.02 rows=1 width=8) (actual time=7766.715..7766.716 rows=0 loops=1)
  2.   Filter: (((checkpoint3_.result IS NOT NULL) AND (SubPlan 2)) OR ((checkpoint3_.resultindicator IS NOT NULL) AND (resultindi4_.result IS NOT NULL) AND (SubPlan 3)))
  3.   Rows Removed by Filter: 1038
  4.   ->  Nested Loop  (cost=1237.59..14520.63 rows=1 width=24) (actual time=682.486..5399.531 rows=1038 loops=1)
  5.         ->  Nested Loop  (cost=1237.16..14294.75 rows=1 width=32) (actual time=19.806..1442.899 rows=1549 loops=1)
  6.               ->  Gather  (cost=1236.74..14291.94 rows=1 width=32) (actual time=19.760..24.942 rows=1549 loops=1)
  7.                     Workers Planned: 2
  8.                     Workers Launched: 2
  9.                     ->  Nested Loop  (cost=236.74..13291.84 rows=1 width=32) (actual time=14.355..2146.118 rows=516 loops=3)
  10.                           ->  Nested Loop  (cost=236.31..13260.10 rows=1 width=24) (actual time=11.139..1066.549 rows=516 loops=3)
  11.                                 ->  Hash Join  (cost=236.02..12660.64 rows=38 width=24) (actual time=5.510..145.831 rows=516 loops=3)
  12.                                       Hash Cond: (resultindi1_.version_meta_id = eventrisks0_.resultindicatoreventexecution)
  13.                                       ->  Parallel Seq Scan on resultindicatoreventexecution resultindi1_  (cost=0.00..12420.27 rows=634 width=24) (actual time=0.669..132.502 rows=13583 loops=3)
  14.                                             Filter: ((NOT version_is_deleted) AND (fpresultsexecution IS NULL) AND (event IS NOT NULL) AND (tsrange(version_actual_period_start, version_actual_period_end, '[]'::text) @> timezone('utc'::text, clock_timestamp())))
  15.                                             Rows Removed by Filter: 191668
  16.                                       ->  Hash  (cost=130.46..130.46 rows=8445 width=16) (actual time=3.386..3.387 rows=8445 loops=3)
  17.                                             Buckets: 16384  Batches: 1  Memory Usage: 524kB
  18.                                             ->  Seq Scan on eventrisks eventrisks0_  (cost=0.00..130.46 rows=8445 width=16) (actual time=0.028..1.933 rows=8445 loops=3)
  19.                                                   Filter: (resultindicatoreventexecution IS NOT NULL)
  20.                                                   Rows Removed by Filter: 1
  21.                                 ->  Index Scan using public_events_not_del_version_period_range_idx on events events2_  (cost=0.29..15.77 rows=1 width=16) (actual time=1.301..1.778 rows=1 loops=1549)
  22.                                       Index Cond: (version_meta_id = resultindi1_.event)
  23.                                       Filter: ((checkpoint IS NOT NULL) AND (tsrange(version_actual_period_start, version_actual_period_end, '[]'::text) @> timezone('utc'::text, clock_timestamp())))
  24.                                       Rows Removed by Filter: 1
  25.                           ->  Index Scan using public_checkpoints_version_period_idx on checkpoints checkpoint3_  (cost=0.43..31.73 rows=1 width=24) (actual time=2.083..2.086 rows=1 loops=1549)
  26.                                 Index Cond: (version_meta_id = events2_.checkpoint)
  27.                                 Filter: ((NOT version_is_deleted) AND (tsrange(version_actual_period_start, version_actual_period_end, '[]'::text) @> timezone('utc'::text, clock_timestamp())))
  28.                                 Rows Removed by Filter: 3
  29.               ->  Index Only Scan using projectrisks_pkey on projectrisks eventrisks0_1_  (cost=0.42..2.81 rows=1 width=8) (actual time=0.912..0.912 rows=1 loops=1549)
  30.                     Index Cond: (id = eventrisks0_.id)
  31.                     Heap Fetches: 1549
  32.         ->  Index Scan using fpresultexecution_pkey on fpresultexecution resultindi1_1_  (cost=0.43..225.88 rows=1 width=8) (actual time=2.551..2.551 rows=1 loops=1549)
  33.               Index Cond: (id = resultindi1_.id)
  34.               Filter: (SubPlan 1)
  35.               Rows Removed by Filter: 0
  36.               SubPlan 1
  37.                 ->  Nested Loop  (cost=12.16..217.47 rows=1 width=0) (actual time=1.564..1.564 rows=1 loops=1549)
  38.                       ->  Nested Loop  (cost=11.73..210.11 rows=2 width=8) (actual time=0.088..0.517 rows=164 loops=1549)
  39.                             ->  Nested Loop  (cost=8.59..151.59 rows=1 width=8) (actual time=0.068..0.174 rows=6 loops=1549)
  40.                                   ->  Bitmap Heap Scan on tasks tasks7_  (cost=4.19..18.21 rows=1 width=8) (actual time=0.019..0.025 rows=3 loops=1549)
  41.                                         Recheck Cond: (projectversion = 2135)
  42.                                         Filter: ((NOT version_is_deleted) AND (tsrange(version_actual_period_start, version_actual_period_end, '[]'::text) @> timezone('utc'::text, clock_timestamp())))
  43.                                         Heap Blocks: exact=3085
  44.                                         ->  Bitmap Index Scan on ind_1677fc3667886b5199de8078078d04b4_simple  (cost=0.00..4.19 rows=6 width=0) (actual time=0.010..0.010 rows=6 loops=1549)
  45.                                               Index Cond: (projectversion = 2135)
  46.                                   ->  Bitmap Heap Scan on results results6_  (cost=4.40..133.37 rows=1 width=16) (actual time=0.042..0.052 rows=2 loops=4107)
  47.                                         Recheck Cond: ((task = tasks7_.version_meta_id) AND (NOT version_is_deleted))
  48.                                         Filter: (tsrange(version_actual_period_start, version_actual_period_end, '[]'::text) @> timezone('utc'::text, clock_timestamp()))
  49.                                         Rows Removed by Filter: 6
  50.                                         Heap Blocks: exact=28196
  51.                                         ->  Bitmap Index Scan on ind_1fde84286c8d4905bd5a463b4ed1b673  (cost=0.00..4.39 rows=33 width=0) (actual time=0.024..0.024 rows=8 loops=4107)
  52.                                               Index Cond: (task = tasks7_.version_meta_id)
  53.                             ->  Bitmap Heap Scan on fpresultsexecution fpresultse5_  (cost=3.14..58.10 rows=42 width=16) (actual time=0.011..0.052 rows=28 loops=9223)
  54.                                   Recheck Cond: (result = results6_.version_meta_id)
  55.                                   Heap Blocks: exact=194977
  56.                                   ->  Bitmap Index Scan on ind_46c4ca8d6d20616dff3de52e442f8921_simple  (cost=0.00..3.13 rows=42 width=0) (actual time=0.006..0.006 rows=30 loops=9223)
  57.                                         Index Cond: (result = results6_.version_meta_id)
  58.                       ->  Index Scan using fpresultexecution_pkey on fpresultexecution fpresultse5_1_  (cost=0.43..3.67 rows=1 width=8) (actual time=0.006..0.006 rows=0 loops=253744)
  59.                             Index Cond: (id = fpresultse5_.id)
  60.                             Filter: ((NOT version_is_deleted) AND ((year = resultindi1_1_.year) OR ((year IS NULL) AND (resultindi1_1_.year IS NULL))) AND ((resultindi1_1_.month = month) OR ((resultindi1_1_.month IS NULL) AND (month IS NULL))) AND (tsrange(version_actual_period_start, version_actual_period_end, '[]'::text) @> timezone('utc'::text, clock_timestamp())))
  61.                             Rows Removed by Filter: 1
  62.   ->  Index Scan using public_resultindicators_version_period_idx on resultindicators resultindi4_  (cost=0.42..1.70 rows=1 width=16) (actual time=1.156..1.159 rows=1 loops=1038)
  63.         Index Cond: (checkpoint3_.resultindicator = version_meta_id)
  64.         Filter: ((NOT version_is_deleted) AND (tsrange(version_actual_period_start, version_actual_period_end, '[]'::text) @> timezone('utc'::text, clock_timestamp())))
  65.         Rows Removed by Filter: 0
  66.   SubPlan 2
  67.     ->  Nested Loop  (cost=22.78..177.84 rows=1 width=0) (actual time=0.641..0.641 rows=0 loops=1038)
  68.           ->  Nested Loop  (cost=22.35..169.38 rows=1 width=8) (actual time=0.636..0.636 rows=0 loops=1038)
  69.                 ->  Nested Loop  (cost=8.59..151.59 rows=1 width=8) (actual time=0.044..0.268 rows=16 loops=1038)
  70.                       ->  Bitmap Heap Scan on tasks tasks10_  (cost=4.19..18.21 rows=1 width=8) (actual time=0.011..0.024 rows=6 loops=1038)
  71.                             Recheck Cond: (projectversion = 2135)
  72.                             Filter: ((NOT version_is_deleted) AND (tsrange(version_actual_period_start, version_actual_period_end, '[]'::text) @> timezone('utc'::text, clock_timestamp())))
  73.                             Heap Blocks: exact=4152
  74.                             ->  Bitmap Index Scan on ind_1677fc3667886b5199de8078078d04b4_simple  (cost=0.00..4.19 rows=6 width=0) (actual time=0.007..0.007 rows=6 loops=1038)
  75.                                   Index Cond: (projectversion = 2135)
  76.                       ->  Bitmap Heap Scan on results results9_  (cost=4.40..133.37 rows=1 width=16) (actual time=0.030..0.038 rows=3 loops=6228)
  77.                             Recheck Cond: ((task = tasks10_.version_meta_id) AND (NOT version_is_deleted))
  78.                             Filter: (tsrange(version_actual_period_start, version_actual_period_end, '[]'::text) @> timezone('utc'::text, clock_timestamp()))
  79.                             Rows Removed by Filter: 7
  80.                             Heap Blocks: exact=48786
  81.                             ->  Bitmap Index Scan on ind_1fde84286c8d4905bd5a463b4ed1b673  (cost=0.00..4.39 rows=33 width=0) (actual time=0.018..0.018 rows=10 loops=6228)
  82.                                   Index Cond: (task = tasks10_.version_meta_id)
  83.                 ->  Bitmap Heap Scan on fpresultsexecution fpresultse8_  (cost=13.76..17.77 rows=1 width=16) (actual time=0.022..0.022 rows=0 loops=16608)
  84.                       Recheck Cond: ((result = results9_.version_meta_id) AND ((result = checkpoint3_.result) OR (result IS NULL)))
  85.                       Filter: ((result = checkpoint3_.result) OR ((result IS NULL) AND (checkpoint3_.result IS NULL)))
  86.                       ->  BitmapAnd  (cost=13.76..13.76 rows=1 width=0) (actual time=0.021..0.021 rows=0 loops=16608)
  87.                             ->  Bitmap Index Scan on ind_46c4ca8d6d20616dff3de52e442f8921_simple  (cost=0.00..3.13 rows=42 width=0) (actual time=0.004..0.004 rows=29 loops=16608)
  88.                                   Index Cond: (result = results9_.version_meta_id)
  89.                             ->  BitmapOr  (cost=10.38..10.38 rows=200 width=0) (actual time=0.016..0.016 rows=0 loops=15570)
  90.                                   ->  Bitmap Index Scan on ind_46c4ca8d6d20616dff3de52e442f8921_simple  (cost=0.00..4.74 rows=42 width=0) (actual time=0.010..0.010 rows=52 loops=15570)
  91.                                         Index Cond: (result = checkpoint3_.result)
  92.                                   ->  Bitmap Index Scan on ind_46c4ca8d6d20616dff3de52e442f8921_simple  (cost=0.00..5.62 rows=159 width=0) (actual time=0.006..0.006 rows=140 loops=15570)
  93.                                         Index Cond: (result IS NULL)
  94.           ->  Index Scan using fpresultexecution_pkey on fpresultexecution fpresultse8_1_  (cost=0.43..8.46 rows=1 width=8) (never executed)
  95.                 Index Cond: (id = fpresultse8_.id)
  96.                 Filter: ((NOT version_is_deleted) AND (tsrange(version_actual_period_start, version_actual_period_end, '[]'::text) @> timezone('utc'::text, clock_timestamp())))
  97.   SubPlan 3
  98.     ->  Nested Loop  (cost=22.78..177.84 rows=1 width=0) (actual time=0.473..0.473 rows=0 loops=1038)
  99.           ->  Nested Loop  (cost=22.35..169.38 rows=1 width=8) (actual time=0.469..0.469 rows=0 loops=1038)
  100.                 ->  Nested Loop  (cost=8.59..151.59 rows=1 width=8) (actual time=0.036..0.218 rows=16 loops=1038)
  101.                       ->  Bitmap Heap Scan on tasks tasks13_  (cost=4.19..18.21 rows=1 width=8) (actual time=0.009..0.019 rows=6 loops=1038)
  102.                             Recheck Cond: (projectversion = 2135)
  103.                             Filter: ((NOT version_is_deleted) AND (tsrange(version_actual_period_start, version_actual_period_end, '[]'::text) @> timezone('utc'::text, clock_timestamp())))
  104.                             Heap Blocks: exact=4152
  105.                             ->  Bitmap Index Scan on ind_1677fc3667886b5199de8078078d04b4_simple  (cost=0.00..4.19 rows=6 width=0) (actual time=0.005..0.005 rows=6 loops=1038)
  106.                                   Index Cond: (projectversion = 2135)
  107.                       ->  Bitmap Heap Scan on results results12_  (cost=4.40..133.37 rows=1 width=16) (actual time=0.024..0.031 rows=3 loops=6228)
  108.                             Recheck Cond: ((task = tasks13_.version_meta_id) AND (NOT version_is_deleted))
  109.                             Filter: (tsrange(version_actual_period_start, version_actual_period_end, '[]'::text) @> timezone('utc'::text, clock_timestamp()))
  110.                             Rows Removed by Filter: 7
  111.                             Heap Blocks: exact=48786
  112.                             ->  Bitmap Index Scan on ind_1fde84286c8d4905bd5a463b4ed1b673  (cost=0.00..4.39 rows=33 width=0) (actual time=0.015..0.015 rows=10 loops=6228)
  113.                                   Index Cond: (task = tasks13_.version_meta_id)
  114.                 ->  Bitmap Heap Scan on fpresultsexecution fpresultse11_  (cost=13.76..17.77 rows=1 width=16) (actual time=0.015..0.015 rows=0 loops=16608)
  115.                       Recheck Cond: ((result = results12_.version_meta_id) AND ((result = resultindi4_.result) OR (result IS NULL)))
  116.                       Filter: ((result = resultindi4_.result) OR ((result IS NULL) AND (resultindi4_.result IS NULL)))
  117.                       ->  BitmapAnd  (cost=13.76..13.76 rows=1 width=0) (actual time=0.014..0.014 rows=0 loops=16608)
  118.                             ->  Bitmap Index Scan on ind_46c4ca8d6d20616dff3de52e442f8921_simple  (cost=0.00..3.13 rows=42 width=0) (actual time=0.004..0.004 rows=29 loops=16608)
  119.                                   Index Cond: (result = results12_.version_meta_id)
  120.                             ->  BitmapOr  (cost=10.38..10.38 rows=200 width=0) (actual time=0.009..0.009 rows=0 loops=15570)
  121.                                   ->  Bitmap Index Scan on ind_46c4ca8d6d20616dff3de52e442f8921_simple  (cost=0.00..4.74 rows=42 width=0) (actual time=0.003..0.003 rows=52 loops=15570)
  122.                                         Index Cond: (result = resultindi4_.result)
  123.                                   ->  Bitmap Index Scan on ind_46c4ca8d6d20616dff3de52e442f8921_simple  (cost=0.00..5.62 rows=159 width=0) (actual time=0.005..0.005 rows=140 loops=15570)
  124.                                         Index Cond: (result IS NULL)
  125.           ->  Index Scan using fpresultexecution_pkey on fpresultexecution fpresultse11_1_  (cost=0.43..8.46 rows=1 width=8) (never executed)
  126.                 Index Cond: (id = fpresultse11_.id)
  127.                 Filter: ((NOT version_is_deleted) AND (tsrange(version_actual_period_start, version_actual_period_end, '[]'::text) @> timezone('utc'::text, clock_timestamp())))
  128. Planning time: 84.969 ms
  129. Execution time: 7767.614 ms
Advertisement
Add Comment
Please, Sign In to add comment