TPC-DS Q19

SF100 · F64 · Estimated plan · Read from bottom to top. Select a step for details.

Plan

Source XML

Loading plan…

Query SQL

Download SQL
SELECT
TOP 100
  i_brand_id AS brand_id,
  i_brand AS brand,
  i_manufact_id,
  i_manufact,
  SUM(ss_ext_sales_price) AS ext_price
FROM date_dim, store_sales, item, customer, customer_address, store
WHERE
  d_date_sk = ss_sold_date_sk
  AND ss_item_sk = i_item_sk
  AND i_manager_id = 24
  AND d_moy = 11
  AND d_year = 2002
  AND ss_customer_sk = c_customer_sk
  AND c_current_addr_sk = ca_address_sk
  AND SUBSTRING(ca_zip, 1, 5) <> SUBSTRING(s_zip, 1, 5)
  AND ss_store_sk = s_store_sk
GROUP BY
  i_brand,
  i_brand_id,
  i_manufact_id,
  i_manufact
ORDER BY
  ext_price DESC,
  i_brand,
  i_brand_id,
  i_manufact_id,
  i_manufact;
Step details

Loading plan…

Green: scan · yellow: join · purple: row movement. Rows and costs are optimiser estimates; costs use model units.