Back to home page

OSCL-LXR

 
 

    


0001 SELECT
0002   dt.d_year,
0003   item.i_brand_id brand_id,
0004   item.i_brand brand,
0005   sum(ss_ext_sales_price) ext_price
0006 FROM date_dim dt, store_sales, item
0007 WHERE dt.d_date_sk = store_sales.ss_sold_date_sk
0008   AND store_sales.ss_item_sk = item.i_item_sk
0009   AND item.i_manager_id = 1
0010   AND dt.d_moy = 11
0011   AND dt.d_year = 2000
0012 GROUP BY dt.d_year, item.i_brand, item.i_brand_id
0013 ORDER BY dt.d_year, ext_price DESC, brand_id
0014 LIMIT 100