This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| *** q77.sql 2016-03-25 14:10:21.910553746 +0100 | |
| --- q77_modified.sql 2016-03-25 14:10:21.910553746 +0100 | |
| *************** | |
| *** 4,63 **** | |
| sum(ss_net_profit) AS profit | |
| FROM "${database}"."${schema}".store_sales, | |
| "${database}"."${schema}".date_dim, | |
| "${database}"."${schema}".store | |
| WHERE ss_sold_date_sk = d_date_sk | |
| ! AND d_date BETWEEN cast('2000-08-18' AS date) AND (cast('2000-08-18' AS date) + 30 days) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| *** q80.sql 2016-03-25 14:10:21.910553746 +0100 | |
| --- q80_modified.sql 2016-03-25 14:10:21.910553746 +0100 | |
| *************** | |
| *** 8,18 **** | |
| AND ss_ticket_number = sr_ticket_number), "${database}"."${schema}".date_dim, | |
| "${database}"."${schema}".store, | |
| "${database}"."${schema}".item, | |
| "${database}"."${schema}".promotion | |
| WHERE ss_sold_date_sk = d_date_sk | |
| ! AND d_date BETWEEN cast('2002-08-05' AS date) AND (cast('2002-08-05' AS date) + 30 days) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| *** q82.sql 2016-03-25 14:10:21.910553746 +0100 | |
| --- q82_modified.sql 2016-03-25 14:10:21.910553746 +0100 | |
| *************** | |
| *** 6,16 **** | |
| "${database}"."${schema}".date_dim, | |
| "${database}"."${schema}".store_sales | |
| WHERE i_current_price BETWEEN 44 AND 44+30 | |
| AND inv_item_sk = i_item_sk | |
| AND d_date_sk=inv_date_sk | |
| ! AND d_date BETWEEN cast('1998-06-13' AS date) AND (cast('1998-06-13' AS date) + 60 days) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| *** q92.sql 2016-03-25 14:10:21.910553746 +0100 | |
| --- q92_modified.sql 2016-03-25 14:10:21.910553746 +0100 | |
| *************** | |
| *** 2,16 **** | |
| FROM "${database}"."${schema}".web_sales, | |
| "${database}"."${schema}".item, | |
| "${database}"."${schema}".date_dim | |
| WHERE i_manufact_id = 961 | |
| AND i_item_sk = ws_item_sk | |
| ! AND d_date BETWEEN '2001-03-04' AND (cast('2001-03-04' AS date) + 90 days) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| *** q94.sql 2016-03-25 14:10:21.910553746 +0100 | |
| --- q94_modified.sql 2016-03-25 14:10:21.910553746 +0100 | |
| *************** | |
| *** 3,13 **** | |
| sum(ws_net_profit) AS "total net profit" | |
| FROM "${database}"."${schema}".web_sales ws1 , | |
| "${database}"."${schema}".date_dim , | |
| "${database}"."${schema}".customer_address , | |
| "${database}"."${schema}".web_site | |
| ! WHERE d_date BETWEEN '2002-3-01' AND (cast('2002-3-01' AS date) + 60 days) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| *** q95.sql 2016-03-25 14:10:21.910553746 +0100 | |
| --- q95_modified.sql 2016-03-25 14:10:21.910553746 +0100 | |
| *************** | |
| *** 11,21 **** | |
| sum(ws_net_profit) AS "total net profit" | |
| FROM "${database}"."${schema}".web_sales ws1 , | |
| "${database}"."${schema}".date_dim , | |
| "${database}"."${schema}".customer_address , | |
| "${database}"."${schema}".web_site | |
| ! WHERE d_date BETWEEN '2000-5-01' AND (cast('2000-5-01' AS date) + 60 days) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| *** q98.sql 2016-03-25 14:10:21.910553746 +0100 | |
| --- q98_modified.sql 2016-03-25 14:10:21.910553746 +0100 | |
| *************** | |
| *** 10,20 **** | |
| WHERE ss_item_sk = i_item_sk | |
| AND i_category IN ('Music', | |
| 'Men', | |
| 'Shoes') | |
| AND ss_sold_date_sk = d_date_sk | |
| ! AND d_date BETWEEN cast('2001-02-24' AS date) AND (cast('2001-02-24' AS date) + 30 days) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| drop table if exists call_center; | |
| create table call_center( | |
| cc_call_center_sk int | |
| , cc_call_center_id string | |
| , cc_rec_start_date string | |
| , cc_rec_end_date string | |
| , cc_closed_date_sk int | |
| , cc_open_date_sk int |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| *** q58.sql 2016-03-29 10:31:47.000000000 +0200 | |
| --- q58_modified.sql 2016-03-29 11:02:31.000000000 +0200 | |
| *************** | |
| *** 63,69 **** | |
| AND ss_item_rev BETWEEN 0.9 * ws_item_rev AND 1.1 * ws_item_rev | |
| AND cs_item_rev BETWEEN 0.9 * ss_item_rev AND 1.1 * ss_item_rev | |
| AND cs_item_rev BETWEEN 0.9 * ws_item_rev AND 1.1 * ws_item_rev | |
| AND ws_item_rev BETWEEN 0.9 * ss_item_rev AND 1.1 * ss_item_rev | |
| AND ws_item_rev BETWEEN 0.9 * cs_item_rev AND 1.1 * cs_item_rev | |
| ! ORDER BY item_id, |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| *** q54.sql 2016-03-29 11:24:05.000000000 +0200 | |
| --- q54_modified.sql 2016-03-29 11:24:28.000000000 +0200 | |
| *************** | |
| *** 42,52 **** | |
| FROM "${database}"."${schema}".date_dim | |
| WHERE d_year = 1999 | |
| AND d_moy = 2) | |
| GROUP BY c_customer_sk), | |
| segments AS | |
| ! (SELECT cast((revenue/50) AS int) AS segment |