                                                                                                            QUERY PLAN                                                                                                            
----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
 Nested Loop  (cost=7111857.33..7111857.56 rows=1 width=64)
   ->  Nested Loop  (cost=6222909.09..6222909.29 rows=1 width=56)
         ->  Nested Loop  (cost=5333871.06..5333871.23 rows=1 width=48)
               ->  Nested Loop  (cost=4444764.70..4444764.84 rows=1 width=40)
                     ->  Nested Loop  (cost=3555732.52..3555732.63 rows=1 width=32)
                           ->  Nested Loop  (cost=2666632.03..2666632.11 rows=1 width=24)
                                 ->  Nested Loop  (cost=1777826.26..1777826.31 rows=1 width=16)
                                       ->  Aggregate  (cost=888956.08..888956.09 rows=1 width=8)
                                             ->  Nested Loop  (cost=2722.01..888910.36 rows=18285 width=0)
                                                   ->  Hash Join  (cost=2721.71..884793.62 rows=74409 width=4)
                                                         Hash Cond: (store_sales.ss_store_sk = store.s_store_sk)
                                                         ->  Hash Join  (cost=2715.26..883239.32 rows=567130 width=8)
                                                               Hash Cond: (store_sales.ss_sold_time_sk = time_dim.t_time_sk)
                                                               ->  Seq Scan on store_sales  (cost=0.00..804917.92 rows=28800992 width=12)
                                                               ->  Hash  (cost=2693.00..2693.00 rows=1781 width=4)
                                                                     ->  Seq Scan on time_dim  (cost=0.00..2693.00 rows=1781 width=4)
                                                                           Filter: ((t_minute >= 30) AND (t_hour = 8))
                                                         ->  Hash  (cost=6.28..6.28 rows=14 width=4)
                                                               ->  Seq Scan on store  (cost=0.00..6.28 rows=14 width=4)
                                                                     Filter: ((s_store_name)::text = 'ese'::text)
                                                   ->  Result Cache  (cost=0.29..0.33 rows=1 width=4)
                                                         Cache Key: store_sales.ss_hdemo_sk
                                                         ->  Index Scan using household_demographics_pkey on household_demographics  (cost=0.28..0.32 rows=1 width=4)
                                                               Index Cond: (hd_demo_sk = store_sales.ss_hdemo_sk)
                                                               Filter: (((hd_dep_count = 2) AND (hd_vehicle_count <= 4)) OR ((hd_dep_count = 1) AND (hd_vehicle_count <= 3)) OR ((hd_dep_count = 4) AND (hd_vehicle_count <= 6)))
                                       ->  Aggregate  (cost=888870.18..888870.19 rows=1 width=8)
                                             ->  Nested Loop  (cost=2721.46..888825.60 rows=17833 width=0)
                                                   ->  Hash Join  (cost=2721.16..884754.83 rows=72570 width=4)
                                                         Hash Cond: (store_sales_1.ss_store_sk = store_1.s_store_sk)
                                                         ->  Hash Join  (cost=2714.71..883238.77 rows=553118 width=8)
                                                               Hash Cond: (store_sales_1.ss_sold_time_sk = time_dim_1.t_time_sk)
                                                               ->  Seq Scan on store_sales store_sales_1  (cost=0.00..804917.92 rows=28800992 width=12)
                                                               ->  Hash  (cost=2693.00..2693.00 rows=1737 width=4)
                                                                     ->  Seq Scan on time_dim time_dim_1  (cost=0.00..2693.00 rows=1737 width=4)
                                                                           Filter: ((t_minute < 30) AND (t_hour = 9))
                                                         ->  Hash  (cost=6.28..6.28 rows=14 width=4)
                                                               ->  Seq Scan on store store_1  (cost=0.00..6.28 rows=14 width=4)
                                                                     Filter: ((s_store_name)::text = 'ese'::text)
                                                   ->  Result Cache  (cost=0.29..0.33 rows=1 width=4)
                                                         Cache Key: store_sales_1.ss_hdemo_sk
                                                         ->  Index Scan using household_demographics_pkey on household_demographics household_demographics_1  (cost=0.28..0.32 rows=1 width=4)
                                                               Index Cond: (hd_demo_sk = store_sales_1.ss_hdemo_sk)
                                                               Filter: (((hd_dep_count = 2) AND (hd_vehicle_count <= 4)) OR ((hd_dep_count = 1) AND (hd_vehicle_count <= 3)) OR ((hd_dep_count = 4) AND (hd_vehicle_count <= 6)))
                                 ->  Aggregate  (cost=888805.78..888805.79 rows=1 width=8)
                                       ->  Nested Loop  (cost=2721.04..888762.04 rows=17494 width=0)
                                             ->  Hash Join  (cost=2720.75..884725.73 rows=71191 width=4)
                                                   Hash Cond: (store_sales_2.ss_store_sk = store_2.s_store_sk)
                                                   ->  Hash Join  (cost=2714.30..883238.36 rows=542610 width=8)
                                                         Hash Cond: (store_sales_2.ss_sold_time_sk = time_dim_2.t_time_sk)
                                                         ->  Seq Scan on store_sales store_sales_2  (cost=0.00..804917.92 rows=28800992 width=12)
                                                         ->  Hash  (cost=2693.00..2693.00 rows=1704 width=4)
                                                               ->  Seq Scan on time_dim time_dim_2  (cost=0.00..2693.00 rows=1704 width=4)
                                                                     Filter: ((t_minute >= 30) AND (t_hour = 9))
                                                   ->  Hash  (cost=6.28..6.28 rows=14 width=4)
                                                         ->  Seq Scan on store store_2  (cost=0.00..6.28 rows=14 width=4)
                                                               Filter: ((s_store_name)::text = 'ese'::text)
                                             ->  Result Cache  (cost=0.29..0.33 rows=1 width=4)
                                                   Cache Key: store_sales_2.ss_hdemo_sk
                                                   ->  Index Scan using household_demographics_pkey on household_demographics household_demographics_2  (cost=0.28..0.32 rows=1 width=4)
                                                         Index Cond: (hd_demo_sk = store_sales_2.ss_hdemo_sk)
                                                         Filter: (((hd_dep_count = 2) AND (hd_vehicle_count <= 4)) OR ((hd_dep_count = 1) AND (hd_vehicle_count <= 3)) OR ((hd_dep_count = 4) AND (hd_vehicle_count <= 6)))
                           ->  Aggregate  (cost=889100.49..889100.50 rows=1 width=8)
                                 ->  Nested Loop  (cost=2722.93..889052.88 rows=19044 width=0)
                                       ->  Hash Join  (cost=2722.64..884858.86 rows=77500 width=4)
                                             Hash Cond: (store_sales_3.ss_store_sk = store_3.s_store_sk)
                                             ->  Hash Join  (cost=2716.19..883240.25 rows=590694 width=8)
                                                   Hash Cond: (store_sales_3.ss_sold_time_sk = time_dim_3.t_time_sk)
                                                   ->  Seq Scan on store_sales store_sales_3  (cost=0.00..804917.92 rows=28800992 width=12)
                                                   ->  Hash  (cost=2693.00..2693.00 rows=1855 width=4)
                                                         ->  Seq Scan on time_dim time_dim_3  (cost=0.00..2693.00 rows=1855 width=4)
                                                               Filter: ((t_minute < 30) AND (t_hour = 10))
                                             ->  Hash  (cost=6.28..6.28 rows=14 width=4)
                                                   ->  Seq Scan on store store_3  (cost=0.00..6.28 rows=14 width=4)
                                                         Filter: ((s_store_name)::text = 'ese'::text)
                                       ->  Result Cache  (cost=0.29..0.33 rows=1 width=4)
                                             Cache Key: store_sales_3.ss_hdemo_sk
                                             ->  Index Scan using household_demographics_pkey on household_demographics household_demographics_3  (cost=0.28..0.32 rows=1 width=4)
                                                   Index Cond: (hd_demo_sk = store_sales_3.ss_hdemo_sk)
                                                   Filter: (((hd_dep_count = 2) AND (hd_vehicle_count <= 4)) OR ((hd_dep_count = 1) AND (hd_vehicle_count <= 3)) OR ((hd_dep_count = 4) AND (hd_vehicle_count <= 6)))
                     ->  Aggregate  (cost=889032.18..889032.19 rows=1 width=8)
                           ->  Nested Loop  (cost=2722.49..888985.46 rows=18685 width=0)
                                 ->  Hash Join  (cost=2722.20..884828.00 rows=76038 width=4)
                                       Hash Cond: (store_sales_4.ss_store_sk = store_4.s_store_sk)
                                       ->  Hash Join  (cost=2715.75..883239.81 rows=579548 width=8)
                                             Hash Cond: (store_sales_4.ss_sold_time_sk = time_dim_4.t_time_sk)
                                             ->  Seq Scan on store_sales store_sales_4  (cost=0.00..804917.92 rows=28800992 width=12)
                                             ->  Hash  (cost=2693.00..2693.00 rows=1820 width=4)
                                                   ->  Seq Scan on time_dim time_dim_4  (cost=0.00..2693.00 rows=1820 width=4)
                                                         Filter: ((t_minute >= 30) AND (t_hour = 10))
                                       ->  Hash  (cost=6.28..6.28 rows=14 width=4)
                                             ->  Seq Scan on store store_4  (cost=0.00..6.28 rows=14 width=4)
                                                   Filter: ((s_store_name)::text = 'ese'::text)
                                 ->  Result Cache  (cost=0.29..0.33 rows=1 width=4)
                                       Cache Key: store_sales_4.ss_hdemo_sk
                                       ->  Index Scan using household_demographics_pkey on household_demographics household_demographics_4  (cost=0.28..0.32 rows=1 width=4)
                                             Index Cond: (hd_demo_sk = store_sales_4.ss_hdemo_sk)
                                             Filter: (((hd_dep_count = 2) AND (hd_vehicle_count <= 4)) OR ((hd_dep_count = 1) AND (hd_vehicle_count <= 3)) OR ((hd_dep_count = 4) AND (hd_vehicle_count <= 6)))
               ->  Aggregate  (cost=889106.36..889106.37 rows=1 width=8)
                     ->  Nested Loop  (cost=2722.97..889058.67 rows=19075 width=0)
                           ->  Hash Join  (cost=2722.68..884861.50 rows=77626 width=4)
                                 Hash Cond: (store_sales_5.ss_store_sk = store_5.s_store_sk)
                                 ->  Hash Join  (cost=2716.22..883240.29 rows=591649 width=8)
                                       Hash Cond: (store_sales_5.ss_sold_time_sk = time_dim_5.t_time_sk)
                                       ->  Seq Scan on store_sales store_sales_5  (cost=0.00..804917.92 rows=28800992 width=12)
                                       ->  Hash  (cost=2693.00..2693.00 rows=1858 width=4)
                                             ->  Seq Scan on time_dim time_dim_5  (cost=0.00..2693.00 rows=1858 width=4)
                                                   Filter: ((t_minute < 30) AND (t_hour = 11))
                                 ->  Hash  (cost=6.28..6.28 rows=14 width=4)
                                       ->  Seq Scan on store store_5  (cost=0.00..6.28 rows=14 width=4)
                                             Filter: ((s_store_name)::text = 'ese'::text)
                           ->  Result Cache  (cost=0.29..0.33 rows=1 width=4)
                                 Cache Key: store_sales_5.ss_hdemo_sk
                                 ->  Index Scan using household_demographics_pkey on household_demographics household_demographics_5  (cost=0.28..0.32 rows=1 width=4)
                                       Index Cond: (hd_demo_sk = store_sales_5.ss_hdemo_sk)
                                       Filter: (((hd_dep_count = 2) AND (hd_vehicle_count <= 4)) OR ((hd_dep_count = 1) AND (hd_vehicle_count <= 3)) OR ((hd_dep_count = 4) AND (hd_vehicle_count <= 6)))
         ->  Aggregate  (cost=889038.03..889038.04 rows=1 width=8)
               ->  Nested Loop  (cost=2722.53..888991.24 rows=18716 width=0)
                     ->  Hash Join  (cost=2722.24..884830.64 rows=76163 width=4)
                           Hash Cond: (store_sales_6.ss_store_sk = store_6.s_store_sk)
                           ->  Hash Join  (cost=2715.79..883239.85 rows=580504 width=8)
                                 Hash Cond: (store_sales_6.ss_sold_time_sk = time_dim_6.t_time_sk)
                                 ->  Seq Scan on store_sales store_sales_6  (cost=0.00..804917.92 rows=28800992 width=12)
                                 ->  Hash  (cost=2693.00..2693.00 rows=1823 width=4)
                                       ->  Seq Scan on time_dim time_dim_6  (cost=0.00..2693.00 rows=1823 width=4)
                                             Filter: ((t_minute >= 30) AND (t_hour = 11))
                           ->  Hash  (cost=6.28..6.28 rows=14 width=4)
                                 ->  Seq Scan on store store_6  (cost=0.00..6.28 rows=14 width=4)
                                       Filter: ((s_store_name)::text = 'ese'::text)
                     ->  Result Cache  (cost=0.29..0.33 rows=1 width=4)
                           Cache Key: store_sales_6.ss_hdemo_sk
                           ->  Index Scan using household_demographics_pkey on household_demographics household_demographics_6  (cost=0.28..0.32 rows=1 width=4)
                                 Index Cond: (hd_demo_sk = store_sales_6.ss_hdemo_sk)
                                 Filter: (((hd_dep_count = 2) AND (hd_vehicle_count <= 4)) OR ((hd_dep_count = 1) AND (hd_vehicle_count <= 3)) OR ((hd_dep_count = 4) AND (hd_vehicle_count <= 6)))
   ->  Aggregate  (cost=888948.25..888948.26 rows=1 width=8)
         ->  Nested Loop  (cost=2721.96..888902.64 rows=18244 width=0)
               ->  Hash Join  (cost=2721.66..884790.09 rows=74241 width=4)
                     Hash Cond: (store_sales_7.ss_store_sk = store_7.s_store_sk)
                     ->  Hash Join  (cost=2715.21..883239.27 rows=565856 width=8)
                           Hash Cond: (store_sales_7.ss_sold_time_sk = time_dim_7.t_time_sk)
                           ->  Seq Scan on store_sales store_sales_7  (cost=0.00..804917.92 rows=28800992 width=12)
                           ->  Hash  (cost=2693.00..2693.00 rows=1777 width=4)
                                 ->  Seq Scan on time_dim time_dim_7  (cost=0.00..2693.00 rows=1777 width=4)
                                       Filter: ((t_minute < 30) AND (t_hour = 12))
                     ->  Hash  (cost=6.28..6.28 rows=14 width=4)
                           ->  Seq Scan on store store_7  (cost=0.00..6.28 rows=14 width=4)
                                 Filter: ((s_store_name)::text = 'ese'::text)
               ->  Result Cache  (cost=0.29..0.33 rows=1 width=4)
                     Cache Key: store_sales_7.ss_hdemo_sk
                     ->  Index Scan using household_demographics_pkey on household_demographics household_demographics_7  (cost=0.28..0.32 rows=1 width=4)
                           Index Cond: (hd_demo_sk = store_sales_7.ss_hdemo_sk)
                           Filter: (((hd_dep_count = 2) AND (hd_vehicle_count <= 4)) OR ((hd_dep_count = 1) AND (hd_vehicle_count <= 3)) OR ((hd_dep_count = 4) AND (hd_vehicle_count <= 6)))
(151 rows)

