How to load your database with the TPCDS benchmark

Query command

This howto will show you how to load a relational database in order to create a benchmark with the data query command.

tpcds is a benchmark and offers 100 queries that we will execute.

All 100 queries are not present because Sqlite does not implement all standard ANSI clause but as since version 3.25 support window functions, most of the analytics query are working.

Steps

Drop all tables

For the purpose of this howto, we will use the Sqlite howto connection

To be sure to start in a clean schema, the below data drop command will drop all tables in the Sqlite howto connection

tabli data drop *@sqlite

Load the TPCDS data into the target system

With the data copy command, we will copy the TPCDS store schema into the Sqlite howto connection.

tabli data copy --with-dependencies store*@tpcds @sqlite
Source                         Target                          Latency (ms)   Row Count   Error   Message
----------------------------   -----------------------------   ------------   ---------   -----   -------
customer@tpcds                 customer@sqlite                 104            1000
customer_address@tpcds         customer_address@sqlite         117            1000
customer_demographics@tpcds    customer_demographics@sqlite    21056          1920800
date_dim@tpcds                 date_dim@sqlite                 5291           73049
household_demographics@tpcds   household_demographics@sqlite   85             7200
income_band@tpcds              income_band@sqlite              23             20
item@tpcds                     item@sqlite                     380            2000
promotion@tpcds                promotion@sqlite                29             3
reason@tpcds                   reason@sqlite                   23             1
store@tpcds                    store@sqlite                    74             2
store_returns@tpcds            store_returns@sqlite            700            11925
store_sales@tpcds              store_sales@sqlite              6542           120527
time_dim@tpcds                 time_dim@sqlite                 1218           86400

We copy only the store star schema to make it quicker but you can try to load all the TPC-DS data

tabli data copy --with-dependencies store*@tpcds @sqlite

Start the query command

The below data query command will select all Tpcds queries located in the tpcds-query connection below the sqlite directory and run them.

tabli data query --not-strict (sqlite/query_*.sql@tpcds_query)@sqlite

The output gives you latency data that you can then analyse.

If you want to get the latency data in another data resource such as a csv or table, you can make use of the output options.

Query Name       Start Time                End Time                  Latency (ms)   Row Count   Error   Error Message
--------------   -----------------------   -----------------------   ------------   ---------   -----   -----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
query_1.sql_1    2020-12-12 19:22:27.824   2020-12-12 19:22:27.894             70         100
query_10.sql_1   2020-12-12 19:22:27.895   2020-12-12 19:22:27.899              4               Err     An error has occurred executing the query. Error Message: [SQLITE_ERROR] SQL error or missing database (no such table: web_sales) Query: select count(1) from (select   cd_gender,  cd_marital_status,  cd_education_status,  count(*) cnt1,  cd_purchase_estimate,  count(*) cnt2,  cd_credit_rating,  count(*) cnt3,  cd_dep_count,  count(*) cnt4,  cd_dep_employed_count,  count(*) cnt5,  cd_dep_college_count,  count(*) cnt6 from  customer c,customer_address ca,customer_demographics where  c.c_current_addr_sk = ca.ca_address_sk and  ca_county in ('Walker County','Richland County','Gaines County','Douglas County','Dona Ana County') and  cd_demo_sk = c.c_current_cdemo_sk and  exists (select *      from store_sales,date_dim      where c.c_customer_sk = ss_customer_sk and         ss_sold_date_sk = d_date_sk and         d_year = 2002 and         d_moy between 4 and 4+3) and  (exists (select *       from web_sales,date_dim       where c.c_customer_sk = ws_bill_customer_sk and          ws_sold_date_sk = d_date_sk and          d_year = 2002 and          d_moy between 4 ANd 4+3) or   exists (select *       from catalog_sales,date_dim       where c.c_customer_sk = cs_ship_customer_sk and          cs_sold_date_sk = d_date_sk and          d_year = 2002 and          d_moy between 4 and 4+3)) group by cd_gender,      cd_marital_status,      cd_education_status,      cd_purchase_estimate,      cd_credit_rating,      cd_dep_count,      cd_dep_employed_count,      cd_dep_college_count order by cd_gender,      cd_marital_status,      cd_education_status,      cd_purchase_estimate,      cd_credit_rating,      cd_dep_count,      cd_dep_employed_count,      cd_dep_college_count limit 100) "script_047ade3df8912d791c3a05fc8a06c9eb"
query_11.sql_1   2020-12-12 19:22:27.899   2020-12-12 19:22:27.901              2               Err     An error has occurred executing the query. Error Message: [SQLITE_ERROR] SQL error or missing database (no such table: web_sales) Query: select count(1) from (with year_total as ( select c_customer_id customer_id    ,c_first_name customer_first_name    ,c_last_name customer_last_name    ,c_preferred_cust_flag customer_preferred_cust_flag    ,c_birth_country customer_birth_country    ,c_login customer_login    ,c_email_address customer_email_address    ,d_year dyear    ,sum(ss_ext_list_price-ss_ext_discount_amt) year_total    ,'s' sale_type from customer   ,store_sales   ,date_dim where c_customer_sk = ss_customer_sk  and ss_sold_date_sk = d_date_sk group by c_customer_id     ,c_first_name     ,c_last_name     ,c_preferred_cust_flag      ,c_birth_country     ,c_login     ,c_email_address     ,d_year  union all select c_customer_id customer_id    ,c_first_name customer_first_name    ,c_last_name customer_last_name    ,c_preferred_cust_flag customer_preferred_cust_flag    ,c_birth_country customer_birth_country    ,c_login customer_login    ,c_email_address customer_email_address    ,d_year dyear    ,sum(ws_ext_list_price-ws_ext_discount_amt) year_total    ,'w' sale_type from customer   ,web_sales   ,date_dim where c_customer_sk = ws_bill_customer_sk  and ws_sold_date_sk = d_date_sk group by c_customer_id     ,c_first_name     ,c_last_name     ,c_preferred_cust_flag      ,c_birth_country     ,c_login     ,c_email_address     ,d_year     )  select           t_s_secyear.customer_id         ,t_s_secyear.customer_first_name         ,t_s_secyear.customer_last_name         ,t_s_secyear.customer_email_address from year_total t_s_firstyear   ,year_total t_s_secyear   ,year_total t_w_firstyear   ,year_total t_w_secyear where t_s_secyear.customer_id = t_s_firstyear.customer_id     and t_s_firstyear.customer_id = t_w_secyear.customer_id     and t_s_firstyear.customer_id = t_w_firstyear.customer_id     and t_s_firstyear.sale_type = 's'     and t_w_firstyear.sale_type = 'w'     and t_s_secyear.sale_type = 's'     and t_w_secyear.sale_type = 'w'     and t_s_firstyear.dyear = 2001     and t_s_secyear.dyear = 2001+1     and t_w_firstyear.dyear = 2001     and t_w_secyear.dyear = 2001+1     and t_s_firstyear.year_total > 0     and t_w_firstyear.year_total > 0     and case when t_w_firstyear.year_total > 0 then t_w_secyear.year_total / t_w_firstyear.year_total else 0.0 end       > case when t_s_firstyear.year_total > 0 then t_s_secyear.year_total / t_s_firstyear.year_total else 0.0 end order by t_s_secyear.customer_id     ,t_s_secyear.customer_first_name     ,t_s_secyear.customer_last_name     ,t_s_secyear.customer_email_address limit 100) "script_4d64ccb9e60791cc6044b5eae7732b2a"
query_12.sql_1   2020-12-12 19:22:27.901   2020-12-12 19:22:27.901              0               Err     An error has occurred executing the query. Error Message: [SQLITE_ERROR] SQL error or missing database (no such table: web_sales) Query: select count(1) from (select i_item_id    ,i_item_desc    ,i_category    ,i_class    ,i_current_price    ,sum(ws_ext_sales_price) as itemrevenue    ,sum(ws_ext_sales_price)*100/sum(sum(ws_ext_sales_price)) over (partition by i_class) as revenueratio from web_sales   ,item   ,date_dim where ws_item_sk = i_item_sk  	and i_category in ('Jewelry', 'Sports', 'Books')  	and ws_sold_date_sk = d_date_sk 	and d_date between date('2001-01-12') and date('2001-01-12','+30 days') group by 	i_item_id     ,i_item_desc     ,i_category     ,i_class     ,i_current_price order by 	i_category     ,i_class     ,i_item_id     ,i_item_desc     ,revenueratio) "script_0f9ea47c2969cdb50e90bea429e08bd1"
query_13.sql_1   2020-12-12 19:22:27.901   2020-12-12 19:22:27.946             45           1
query_14.sql_1   2020-12-12 19:22:27.946   2020-12-12 19:22:27.948              2               Err     An error has occurred executing the query. Error Message: [SQLITE_ERROR] SQL error or missing database (no such table: web_sales) Query: select count(1) from (with cross_items as ( 	select 		i_item_sk ss_item_sk 	from 		item, 		( 			select 				iss.i_brand_id brand_id , 				iss.i_class_id class_id , 				iss.i_category_id category_id 			from 				store_sales , 				item iss , 				date_dim d1 			where 				ss_item_sk = iss.i_item_sk 				and ss_sold_date_sk = d1.d_date_sk 				and d1.d_year between 1998 AND 1998 + 2 		intersect select 				ics.i_brand_id , 				ics.i_class_id , 				ics.i_category_id 			from 				catalog_sales , 				item ics , 				date_dim d2 			where 				cs_item_sk = ics.i_item_sk 				and cs_sold_date_sk = d2.d_date_sk 				and d2.d_year between 1998 AND 1998 + 2 		intersect select 				iws.i_brand_id , 				iws.i_class_id , 				iws.i_category_id 			from 				web_sales , 				item iws , 				date_dim d3 			where 				ws_item_sk = iws.i_item_sk 				and ws_sold_date_sk = d3.d_date_sk 				and d3.d_year between 1998 AND 1998 + 2 		) 	where 		i_brand_id = brand_id 		and i_class_id = class_id 		and i_category_id = category_id ), avg_sales as ( 	select 		avg(quantity*list_price) average_sales 	from 		( 			select 				ss_quantity quantity , 				ss_list_price list_price 			from 				store_sales , 				date_dim 			where 				ss_sold_date_sk = d_date_sk 				and d_year between 1998 and 1998 + 2 		union all select 				cs_quantity quantity , 				cs_list_price list_price 			from 				catalog_sales , 				date_dim 			where 				cs_sold_date_sk = d_date_sk 				and d_year between 1998 and 1998 + 2 		union all select 				ws_quantity quantity , 				ws_list_price list_price 			from 				web_sales , 				date_dim 			where 				ws_sold_date_sk = d_date_sk 				and d_year between 1998 and 1998 + 2 		) x ) select 	channel, 	i_brand_id, 	i_class_id, 	i_category_id 	, sum(sales) , 	sum(number_sales) from 	( 		select 			'store' channel, 			i_brand_id, 			i_class_id , 			i_category_id, 			sum(ss_quantity*ss_list_price) sales , 			count(*) number_sales 		from 			store_sales , 			item , 			date_dim 		where 			ss_item_sk in ( 				select 					ss_item_sk 				from 					cross_items 			) 			and ss_item_sk = i_item_sk 			and ss_sold_date_sk = d_date_sk 			and d_year = 1998 + 2 			and d_moy = 11 		group by 			i_brand_id, 			i_class_id, 			i_category_id 		having 			sum(ss_quantity*ss_list_price) > ( 				select 					average_sales 				from 					avg_sales 			) 	union all select 			'catalog' channel, 			i_brand_id, 			i_class_id, 			i_category_id, 			sum(cs_quantity*cs_list_price) sales, 			count(*) number_sales 		from 			catalog_sales , 			item , 			date_dim 		where 			cs_item_sk in ( 				select 					ss_item_sk 				from 					cross_items 			) 			and cs_item_sk = i_item_sk 			and cs_sold_date_sk = d_date_sk 			and d_year = 1998 + 2 			and d_moy = 11 		group by 			i_brand_id, 			i_class_id, 			i_category_id 		having 			sum(cs_quantity*cs_list_price) > ( 				select 					average_sales 				from 					avg_sales 			) 	union all select 			'web' channel, 			i_brand_id, 			i_class_id, 			i_category_id, 			sum(ws_quantity*ws_list_price) sales , 			count(*) number_sales 		from 			web_sales , 			item , 			date_dim 		where 			ws_item_sk in ( 				select 					ss_item_sk 				from 					cross_items 			) 			and ws_item_sk = i_item_sk 			and ws_sold_date_sk = d_date_sk 			and d_year = 1998 + 2 			and d_moy = 11 		group by 			i_brand_id, 			i_class_id, 			i_category_id 		having 			sum(ws_quantity*ws_list_price) > ( 				select 					average_sales 				from 					avg_sales 			) 	) y -- No rollup --group by rollup (channel, i_brand_id,i_class_id,i_category_id) group by 		y.channel, 		y.i_brand_id, 		y.i_class_id, 		y.i_category_id order by 	channel, 	i_brand_id, 	i_class_id, 	i_category_id limit 100) "script_1bc87091763393aa15c835d16583a3b9"
query_14.sql_2   2020-12-12 19:22:27.948   2020-12-12 19:22:27.949              1               Err     An error has occurred executing the query. Error Message: [SQLITE_ERROR] SQL error or missing database (no such table: web_sales) Query: select count(1) from (with cross_items as ( 	select 		i_item_sk ss_item_sk 	from 		item, 		( 			select 				iss.i_brand_id brand_id , 				iss.i_class_id class_id , 				iss.i_category_id category_id 			from 				store_sales , 				item iss , 				date_dim d1 			where 				ss_item_sk = iss.i_item_sk 				and ss_sold_date_sk = d1.d_date_sk 				and d1.d_year between 1998 AND 1998 + 2 		intersect select 				ics.i_brand_id , 				ics.i_class_id , 				ics.i_category_id 			from 				catalog_sales , 				item ics , 				date_dim d2 			where 				cs_item_sk = ics.i_item_sk 				and cs_sold_date_sk = d2.d_date_sk 				and d2.d_year between 1998 AND 1998 + 2 		intersect select 				iws.i_brand_id , 				iws.i_class_id , 				iws.i_category_id 			from 				web_sales , 				item iws , 				date_dim d3 			where 				ws_item_sk = iws.i_item_sk 				and ws_sold_date_sk = d3.d_date_sk 				and d3.d_year between 1998 AND 1998 + 2 		) 	where 		i_brand_id = brand_id 		and i_class_id = class_id 		and i_category_id = category_id ), avg_sales as ( 	select 		avg(quantity*list_price) average_sales 	from 		( 			select 				ss_quantity quantity , 				ss_list_price list_price 			from 				store_sales , 				date_dim 			where 				ss_sold_date_sk = d_date_sk 				and d_year between 1998 and 1998 + 2 		union all select 				cs_quantity quantity , 				cs_list_price list_price 			from 				catalog_sales , 				date_dim 			where 				cs_sold_date_sk = d_date_sk 				and d_year between 1998 and 1998 + 2 		union all select 				ws_quantity quantity , 				ws_list_price list_price 			from 				web_sales , 				date_dim 			where 				ws_sold_date_sk = d_date_sk 				and d_year between 1998 and 1998 + 2 		) x ) select 	channel, 	i_brand_id, 	i_class_id, 	i_category_id 	, sum(sales) , 	sum(number_sales) from 	( 		select 			'store' channel, 			i_brand_id, 			i_class_id , 			i_category_id, 			sum(ss_quantity*ss_list_price) sales , 			count(*) number_sales 		from 			store_sales , 			item , 			date_dim 		where 			ss_item_sk in ( 				select 					ss_item_sk 				from 					cross_items 			) 			and ss_item_sk = i_item_sk 			and ss_sold_date_sk = d_date_sk 			and d_year = 1998 + 2 			and d_moy = 11 		group by 			i_brand_id, 			i_class_id, 			i_category_id 		having 			sum(ss_quantity*ss_list_price) > ( 				select 					average_sales 				from 					avg_sales 			) 	union all select 			'catalog' channel, 			i_brand_id, 			i_class_id, 			i_category_id, 			sum(cs_quantity*cs_list_price) sales, 			count(*) number_sales 		from 			catalog_sales , 			item , 			date_dim 		where 			cs_item_sk in ( 				select 					ss_item_sk 				from 					cross_items 			) 			and cs_item_sk = i_item_sk 			and cs_sold_date_sk = d_date_sk 			and d_year = 1998 + 2 			and d_moy = 11 		group by 			i_brand_id, 			i_class_id, 			i_category_id 		having 			sum(cs_quantity*cs_list_price) > ( 				select 					average_sales 				from 					avg_sales 			) 	union all select 			'web' channel, 			i_brand_id, 			i_class_id, 			i_category_id, 			sum(ws_quantity*ws_list_price) sales , 			count(*) number_sales 		from 			web_sales , 			item , 			date_dim 		where 			ws_item_sk in ( 				select 					ss_item_sk 				from 					cross_items 			) 			and ws_item_sk = i_item_sk 			and ws_sold_date_sk = d_date_sk 			and d_year = 1998 + 2 			and d_moy = 11 		group by 			i_brand_id, 			i_class_id, 			i_category_id 		having 			sum(ws_quantity*ws_list_price) > ( 				select 					average_sales 				from 					avg_sales 			) 	) y -- No rollup --group by rollup (channel, i_brand_id,i_class_id,i_category_id) group by 		y.channel, 		y.i_brand_id, 		y.i_class_id, 		y.i_category_id order by 	channel, 	i_brand_id, 	i_class_id, 	i_category_id limit 100) "script_1bc87091763393aa15c835d16583a3b9"
query_15.sql_1   2020-12-12 19:22:27.949   2020-12-12 19:22:27.95               1               Err     An error has occurred executing the query. Error Message: [SQLITE_ERROR] SQL error or missing database (no such table: catalog_sales) Query: select count(1) from (select ca_zip    ,sum(cs_sales_price) from catalog_sales   ,customer   ,customer_address   ,date_dim where cs_bill_customer_sk = c_customer_sk 	and c_current_addr_sk = ca_address_sk  	and ( substr(ca_zip,1,5) in ('85669', '86197','88274','83405','86475',                  '85392', '85460', '80348', '81792') 	   or ca_state in ('CA','WA','GA') 	   or cs_sales_price > 500) 	and cs_sold_date_sk = d_date_sk 	and d_qoy = 2 and d_year = 2000 group by ca_zip order by ca_zip limit 100) "script_5515e3a5cdb8a516ed97ff3d3d05c58c"
query_18.sql_1   2020-12-12 19:22:27.95    2020-12-12 19:22:27.95               0               Err     An error has occurred executing the query. Error Message: [SQLITE_ERROR] SQL error or missing database (no such table: catalog_sales) Query: select count(1) from (select i_item_id,     ca_country,     ca_state,     ca_county,     avg( cast(cs_quantity as decimal(12,2))) agg1,     avg( cast(cs_list_price as decimal(12,2))) agg2,     avg( cast(cs_coupon_amt as decimal(12,2))) agg3,     avg( cast(cs_sales_price as decimal(12,2))) agg4,     avg( cast(cs_net_profit as decimal(12,2))) agg5,     avg( cast(c_birth_year as decimal(12,2))) agg6,     avg( cast(cd1.cd_dep_count as decimal(12,2))) agg7 from catalog_sales, customer_demographics cd1,    customer_demographics cd2, customer, customer_address, date_dim, item where cs_sold_date_sk = d_date_sk and    cs_item_sk = i_item_sk and    cs_bill_cdemo_sk = cd1.cd_demo_sk and    cs_bill_customer_sk = c_customer_sk and    cd1.cd_gender = 'M' and     cd1.cd_education_status = 'College' and    c_current_cdemo_sk = cd2.cd_demo_sk and    c_current_addr_sk = ca_address_sk and    c_birth_month in (8,4,12,4,12,10) and    d_year = 2001 and    ca_state in ('ND','WI','AL'          ,'NC','OK','MS','TN') --group by rollup (i_item_id, ca_country, ca_state, ca_county) group by i_item_id, ca_country, ca_state, ca_county order by ca_country,     ca_state,     ca_county, 	i_item_id limit 100) "script_69b7e10790997aad8e8bf7312274480f"
query_19.sql_1   2020-12-12 19:22:27.951   2020-12-12 19:22:27.979             28          17
query_2.sql_1    2020-12-12 19:22:27.979   2020-12-12 19:22:27.98               1               Err     An error has occurred executing the query. Error Message: [SQLITE_ERROR] SQL error or missing database (no such table: catalog_sales) Query: select count(1) from (with wscs as (select sold_date_sk     ,sales_price  from ( 		select ws_sold_date_sk sold_date_sk        ,ws_ext_sales_price sales_price     from web_sales     union all     select cs_sold_date_sk sold_date_sk        ,cs_ext_sales_price sales_price     from catalog_sales 		) ), wswscs as  (select d_week_seq,     sum(case when (d_day_name='Sunday') then sales_price else null end) sun_sales,     sum(case when (d_day_name='Monday') then sales_price else null end) mon_sales,     sum(case when (d_day_name='Tuesday') then sales_price else null end) tue_sales,     sum(case when (d_day_name='Wednesday') then sales_price else null end) wed_sales,     sum(case when (d_day_name='Thursday') then sales_price else null end) thu_sales,     sum(case when (d_day_name='Friday') then sales_price else null end) fri_sales,     sum(case when (d_day_name='Saturday') then sales_price else null end) sat_sales from wscs   ,date_dim where d_date_sk = sold_date_sk group by d_week_seq) select d_week_seq1    ,round(sun_sales1/sun_sales2,2)    ,round(mon_sales1/mon_sales2,2)    ,round(tue_sales1/tue_sales2,2)    ,round(wed_sales1/wed_sales2,2)    ,round(thu_sales1/thu_sales2,2)    ,round(fri_sales1/fri_sales2,2)    ,round(sat_sales1/sat_sales2,2) from (select wswscs.d_week_seq d_week_seq1     ,sun_sales sun_sales1     ,mon_sales mon_sales1     ,tue_sales tue_sales1     ,wed_sales wed_sales1     ,thu_sales thu_sales1     ,fri_sales fri_sales1     ,sat_sales sat_sales1  from wswscs,date_dim  where date_dim.d_week_seq = wswscs.d_week_seq and     d_year = 2001) y, (select wswscs.d_week_seq d_week_seq2     ,sun_sales sun_sales2     ,mon_sales mon_sales2     ,tue_sales tue_sales2     ,wed_sales wed_sales2     ,thu_sales thu_sales2     ,fri_sales fri_sales2     ,sat_sales sat_sales2  from wswscs    ,date_dim  where date_dim.d_week_seq = wswscs.d_week_seq and     d_year = 2001+1) z where d_week_seq1=d_week_seq2-53 order by d_week_seq1) "script_de923ea06f3c87a2da8fb4011e85af34"
query_20.sql_1   2020-12-12 19:22:27.98    2020-12-12 19:22:27.981              1               Err     An error has occurred executing the query. Error Message: [SQLITE_ERROR] SQL error or missing database (no such table: catalog_sales) Query: select count(1) from (select i_item_id    ,i_item_desc     ,i_category     ,i_class     ,i_current_price    ,sum(cs_ext_sales_price) as itemrevenue     ,sum(cs_ext_sales_price)*100/sum(sum(cs_ext_sales_price)) over      (partition by i_class) as revenueratio from	catalog_sales   ,item    ,date_dim where cs_item_sk = i_item_sk   and i_category in ('Jewelry', 'Sports', 'Books')  and cs_sold_date_sk = d_date_sk --and d_date between cast('2001-01-12' as date)  --				and (cast('2001-01-12' as date) + 30 days) and d_date between date('2001-01-12')  				and date('2001-01-12','+30 days') group by i_item_id     ,i_item_desc      ,i_category     ,i_class     ,i_current_price order by i_category     ,i_class     ,i_item_id     ,i_item_desc     ,revenueratio limit 100) "script_a2812e86afbadecb2a5635b083c01b18"
query_21.sql_1   2020-12-12 19:22:27.981   2020-12-12 19:22:27.981              0               Err     An error has occurred executing the query. Error Message: [SQLITE_ERROR] SQL error or missing database (no such table: inventory) Query: select count(1) from (select * from(select w_warehouse_name       ,i_item_id       ,sum(case when (cast(d_date as date) < cast ('1998-04-08' as date)) 	        then inv_quantity_on_hand            else 0 end) as inv_before       ,sum(case when (cast(d_date as date) >= cast ('1998-04-08' as date))            then inv_quantity_on_hand            else 0 end) as inv_after  from inventory    ,warehouse    ,item    ,date_dim  where i_current_price between 0.99 and 1.49   and i_item_sk     = inv_item_sk   and inv_warehouse_sk  = w_warehouse_sk   and inv_date_sk  = d_date_sk   --and d_date between (cast ('1998-04-08' as date) - 30 days) --          and (cast ('1998-04-08' as date) + 30 days) 	and d_date between date('1998-04-08', '-30 days')           and date('1998-04-08', '+30 days')  group by w_warehouse_name, i_item_id) x where (case when inv_before > 0        then inv_after / inv_before        else null       end) between 2.0/3.0 and 3.0/2.0 order by w_warehouse_name     ,i_item_id limit 100) "script_28d463b55546b21e4d00bd72b327355c"
query_22.sql_1   2020-12-12 19:22:27.981   2020-12-12 19:22:27.982              1               Err     An error has occurred executing the query. Error Message: [SQLITE_ERROR] SQL error or missing database (no such table: inventory) Query: select count(1) from (select i_product_name       ,i_brand       ,i_class       ,i_category       ,avg(inv_quantity_on_hand) qoh    from inventory      ,date_dim      ,item    where inv_date_sk=d_date_sk        and inv_item_sk=i_item_sk        and d_month_seq between 1212 and 1212 + 11    --group by rollup(i_product_name ,i_brand ,i_class ,i_category)    group by i_product_name ,i_brand ,i_class ,i_category order by qoh, i_product_name, i_brand, i_class, i_category limit 100) "script_0ca1ca1b4500c34f6763d8ffade63fd2"
query_23.sql_1   2020-12-12 19:22:27.982   2020-12-12 19:22:27.982              0               Err     An error has occurred executing the query. Error Message: [SQLITE_ERROR] SQL error or missing database (no such table: web_sales) Query: select count(1) from (with frequent_ss_items as  (select substr(i_item_desc,1,30) itemdesc,i_item_sk item_sk,d_date solddate,count(*) cnt  from store_sales    ,date_dim    ,item  where ss_sold_date_sk = d_date_sk   and ss_item_sk = i_item_sk   and d_year in (1999,1999+1,1999+2,1999+3)  group by substr(i_item_desc,1,30),i_item_sk,d_date  having count(*) >4), max_store_sales as (select max(csales) tpcds_cmax  from (select c_customer_sk,sum(ss_quantity*ss_sales_price) csales     from store_sales       ,customer       ,date_dim     where ss_customer_sk = c_customer_sk     and ss_sold_date_sk = d_date_sk     and d_year in (1999,1999+1,1999+2,1999+3)     group by c_customer_sk)), best_ss_customer as (select c_customer_sk,sum(ss_quantity*ss_sales_price) ssales  from store_sales    ,customer  where ss_customer_sk = c_customer_sk  group by c_customer_sk  having sum(ss_quantity*ss_sales_price) > (95/100.0) * (select  * from max_store_sales))  select sum(sales) from (select cs_quantity*cs_list_price sales    from catalog_sales      ,date_dim     where d_year = 1999      and d_moy = 1      and cs_sold_date_sk = d_date_sk      and cs_item_sk in (select item_sk from frequent_ss_items)     and cs_bill_customer_sk in (select c_customer_sk from best_ss_customer)    union all    select ws_quantity*ws_list_price sales    from web_sales       ,date_dim     where d_year = 1999      and d_moy = 1      and ws_sold_date_sk = d_date_sk      and ws_item_sk in (select item_sk from frequent_ss_items)     and ws_bill_customer_sk in (select c_customer_sk from best_ss_customer))  limit 100) "script_ced23efc0fdb05b611ddb731f25027ab"
query_23.sql_2   2020-12-12 19:22:27.983   2020-12-12 19:22:27.983              0               Err     An error has occurred executing the query. Error Message: [SQLITE_ERROR] SQL error or missing database (no such table: web_sales) Query: select count(1) from (with frequent_ss_items as  (select substr(i_item_desc,1,30) itemdesc,i_item_sk item_sk,d_date solddate,count(*) cnt  from store_sales    ,date_dim    ,item  where ss_sold_date_sk = d_date_sk   and ss_item_sk = i_item_sk   and d_year in (1999,1999+1,1999+2,1999+3)  group by substr(i_item_desc,1,30),i_item_sk,d_date  having count(*) >4), max_store_sales as (select max(csales) tpcds_cmax  from (select c_customer_sk,sum(ss_quantity*ss_sales_price) csales     from store_sales       ,customer       ,date_dim     where ss_customer_sk = c_customer_sk     and ss_sold_date_sk = d_date_sk     and d_year in (1999,1999+1,1999+2,1999+3)     group by c_customer_sk)), best_ss_customer as (select c_customer_sk,sum(ss_quantity*ss_sales_price) ssales  from store_sales    ,customer  where ss_customer_sk = c_customer_sk  group by c_customer_sk  having sum(ss_quantity*ss_sales_price) > (95/100.0) * (select  * from max_store_sales))  select sum(sales) from (select cs_quantity*cs_list_price sales    from catalog_sales      ,date_dim     where d_year = 1999      and d_moy = 1      and cs_sold_date_sk = d_date_sk      and cs_item_sk in (select item_sk from frequent_ss_items)     and cs_bill_customer_sk in (select c_customer_sk from best_ss_customer)    union all    select ws_quantity*ws_list_price sales    from web_sales       ,date_dim     where d_year = 1999      and d_moy = 1      and ws_sold_date_sk = d_date_sk      and ws_item_sk in (select item_sk from frequent_ss_items)     and ws_bill_customer_sk in (select c_customer_sk from best_ss_customer))  limit 100) "script_ced23efc0fdb05b611ddb731f25027ab"
query_24.sql_1   2020-12-12 19:22:27.983   2020-12-12 19:22:28.048             65           0
query_24.sql_2   2020-12-12 19:22:28.048   2020-12-12 19:22:28.114             66           0
query_25.sql_1   2020-12-12 19:22:28.114   2020-12-12 19:22:28.115              1               Err     An error has occurred executing the query. Error Message: [SQLITE_ERROR] SQL error or missing database (no such table: catalog_sales) Query: select count(1) from (select  i_item_id ,i_item_desc ,s_store_id ,s_store_name ,sum(ss_net_profit) as store_sales_profit ,sum(sr_net_loss) as store_returns_loss ,sum(cs_net_profit) as catalog_sales_profit from store_sales ,store_returns ,catalog_sales ,date_dim d1 ,date_dim d2 ,date_dim d3 ,store ,item where d1.d_moy = 4 and d1.d_year = 2000 and d1.d_date_sk = ss_sold_date_sk and i_item_sk = ss_item_sk and s_store_sk = ss_store_sk and ss_customer_sk = sr_customer_sk and ss_item_sk = sr_item_sk and ss_ticket_number = sr_ticket_number and sr_returned_date_sk = d2.d_date_sk and d2.d_moy        between 4 and 10 and d2.d_year       = 2000 and sr_customer_sk = cs_bill_customer_sk and sr_item_sk = cs_item_sk and cs_sold_date_sk = d3.d_date_sk and d3.d_moy        between 4 and 10  and d3.d_year       = 2000 group by i_item_id ,i_item_desc ,s_store_id ,s_store_name order by i_item_id ,i_item_desc ,s_store_id ,s_store_name limit 100) "script_8eb5f9a9a195714631405196d46b5ad2"
query_26.sql_1   2020-12-12 19:22:28.115   2020-12-12 19:22:28.116              1               Err     An error has occurred executing the query. Error Message: [SQLITE_ERROR] SQL error or missing database (no such table: catalog_sales) Query: select count(1) from (select i_item_id,     avg(cs_quantity) agg1,     avg(cs_list_price) agg2,     avg(cs_coupon_amt) agg3,     avg(cs_sales_price) agg4  from catalog_sales, customer_demographics, date_dim, item, promotion where cs_sold_date_sk = d_date_sk and    cs_item_sk = i_item_sk and    cs_bill_cdemo_sk = cd_demo_sk and    cs_promo_sk = p_promo_sk and    cd_gender = 'F' and     cd_marital_status = 'W' and    cd_education_status = 'Primary' and    (p_channel_email = 'N' or p_channel_event = 'N') and    d_year = 1998  group by i_item_id order by i_item_id limit 100) "script_5aa672aa26bf5daf07f7e7fe42e35f92"
query_27.sql_1   2020-12-12 19:22:28.116   2020-12-12 19:22:28.223            107         100
query_28.sql_1   2020-12-12 19:22:28.223   2020-12-12 19:22:28.339            116           1
query_29.sql_1   2020-12-12 19:22:28.339   2020-12-12 19:22:28.339              0               Err     An error has occurred executing the query. Error Message: [SQLITE_ERROR] SQL error or missing database (no such table: catalog_sales) Query: select count(1) from (select     i_item_id   ,i_item_desc   ,s_store_id   ,s_store_name   ,sum(ss_quantity)    as store_sales_quantity   ,sum(sr_return_quantity) as store_returns_quantity   ,sum(cs_quantity)    as catalog_sales_quantity from   store_sales  ,store_returns  ,catalog_sales  ,date_dim       d1  ,date_dim       d2  ,date_dim       d3  ,store  ,item where   d1.d_moy        = 4  and d1.d_year       = 1999 and d1.d_date_sk      = ss_sold_date_sk and i_item_sk       = ss_item_sk and s_store_sk       = ss_store_sk and ss_customer_sk     = sr_customer_sk and ss_item_sk       = sr_item_sk and ss_ticket_number    = sr_ticket_number and sr_returned_date_sk  = d2.d_date_sk and d2.d_moy        between 4 and 4 + 3  and d2.d_year       = 1999 and sr_customer_sk     = cs_bill_customer_sk and sr_item_sk       = cs_item_sk and cs_sold_date_sk    = d3.d_date_sk    and d3.d_year       in (1999,1999+1,1999+2) group by   i_item_id  ,i_item_desc  ,s_store_id  ,s_store_name order by   i_item_id   ,i_item_desc  ,s_store_id  ,s_store_name limit 100) "script_441cb2a06fae126eae0b15bdf5bc0f2e"
query_3.sql_1    2020-12-12 19:22:28.339   2020-12-12 19:22:28.37              31           2
query_30.sql_1   2020-12-12 19:22:28.37    2020-12-12 19:22:28.371              1               Err     An error has occurred executing the query. Error Message: [SQLITE_ERROR] SQL error or missing database (no such table: web_returns) Query: select count(1) from (with customer_total_return as (select wr_returning_customer_sk as ctr_customer_sk     ,ca_state as ctr_state,  	sum(wr_return_amt) as ctr_total_return from web_returns   ,date_dim   ,customer_address where wr_returned_date_sk = d_date_sk   and d_year =2002  and wr_returning_addr_sk = ca_address_sk  group by wr_returning_customer_sk     ,ca_state)  select c_customer_id,c_salutation,c_first_name,c_last_name,c_preferred_cust_flag    ,c_birth_day,c_birth_month,c_birth_year,c_birth_country,c_login,c_email_address    ,c_last_review_date_sk,ctr_total_return from customer_total_return ctr1   ,customer_address   ,customer where ctr1.ctr_total_return > (select avg(ctr_total_return)*1.2 			 from customer_total_return ctr2          	 where ctr1.ctr_state = ctr2.ctr_state)    and ca_address_sk = c_current_addr_sk    and ca_state = 'IL'    and ctr1.ctr_customer_sk = c_customer_sk order by c_customer_id,c_salutation,c_first_name,c_last_name,c_preferred_cust_flag          ,c_birth_day,c_birth_month,c_birth_year,c_birth_country,c_login,c_email_address          ,c_last_review_date_sk,ctr_total_return limit 100) "script_37d0610fe997a18d1a17bb4ce90804ea"
query_31.sql_1   2020-12-12 19:22:28.371   2020-12-12 19:22:28.372              1               Err     An error has occurred executing the query. Error Message: [SQLITE_ERROR] SQL error or missing database (no such table: web_sales) Query: select count(1) from (with ss as (select ca_county,d_qoy, d_year,sum(ss_ext_sales_price) as store_sales from store_sales,date_dim,customer_address where ss_sold_date_sk = d_date_sk  and ss_addr_sk=ca_address_sk group by ca_county,d_qoy, d_year), ws as (select ca_county,d_qoy, d_year,sum(ws_ext_sales_price) as web_sales from web_sales,date_dim,customer_address where ws_sold_date_sk = d_date_sk  and ws_bill_addr_sk=ca_address_sk group by ca_county,d_qoy, d_year) select     ss1.ca_county    ,ss1.d_year    ,ws2.web_sales/ws1.web_sales web_q1_q2_increase    ,ss2.store_sales/ss1.store_sales store_q1_q2_increase    ,ws3.web_sales/ws2.web_sales web_q2_q3_increase    ,ss3.store_sales/ss2.store_sales store_q2_q3_increase from     ss ss1    ,ss ss2    ,ss ss3    ,ws ws1    ,ws ws2    ,ws ws3 where   ss1.d_qoy = 1   and ss1.d_year = 2000   and ss1.ca_county = ss2.ca_county   and ss2.d_qoy = 2   and ss2.d_year = 2000 and ss2.ca_county = ss3.ca_county   and ss3.d_qoy = 3   and ss3.d_year = 2000   and ss1.ca_county = ws1.ca_county   and ws1.d_qoy = 1   and ws1.d_year = 2000   and ws1.ca_county = ws2.ca_county   and ws2.d_qoy = 2   and ws2.d_year = 2000   and ws1.ca_county = ws3.ca_county   and ws3.d_qoy = 3   and ws3.d_year =2000   and case when ws1.web_sales > 0 then ws2.web_sales/ws1.web_sales else null end     > case when ss1.store_sales > 0 then ss2.store_sales/ss1.store_sales else null end   and case when ws2.web_sales > 0 then ws3.web_sales/ws2.web_sales else null end    > case when ss2.store_sales > 0 then ss3.store_sales/ss2.store_sales else null end order by ss1.d_year) "script_485ad091bf305e9bf3f795d0a7092075"
query_32.sql_1   2020-12-12 19:22:28.372   2020-12-12 19:22:28.373              1               Err     An error has occurred executing the query. Error Message: [SQLITE_ERROR] SQL error or missing database (no such table: catalog_sales) Query: select count(1) from (select sum(cs_ext_discount_amt) as "excess discount amount" from   catalog_sales   ,item   ,date_dim where i_manufact_id = 269 and i_item_sk = cs_item_sk -- and d_date between '1998-03-18' and (cast('1998-03-18' as date) + 90 days) and d_date between date('1998-03-18') and date('1998-03-18', '+90 days') and d_date_sk = cs_sold_date_sk and cs_ext_discount_amt    > (      select       1.3 * avg(cs_ext_discount_amt)      from       catalog_sales       ,date_dim     where        cs_item_sk = i_item_sk      --and d_date between '1998-03-18' and      --          (cast('1998-03-18' as date) + 90 days)      and d_date between date('1998-03-18') and               date('1998-03-18', '+90 days')      and d_date_sk = cs_sold_date_sk    ) limit 100) "script_eeb0911109421525583c27eb8363ea92"
query_33.sql_1   2020-12-12 19:22:28.373   2020-12-12 19:22:28.374              1               Err     An error has occurred executing the query. Error Message: [SQLITE_ERROR] SQL error or missing database (no such table: catalog_sales) Query: select count(1) from (with ss as ( select      i_manufact_id,sum(ss_ext_sales_price) total_sales from 	store_sales, 	date_dim,     customer_address,     item where     i_manufact_id in (select  i_manufact_id from item where i_category in ('Books')) and   ss_item_sk       = i_item_sk and   ss_sold_date_sk     = d_date_sk and   d_year         = 1999 and   d_moy          = 3 and   ss_addr_sk       = ca_address_sk and   ca_gmt_offset      = -5  group by i_manufact_id), cs as ( select      i_manufact_id,sum(cs_ext_sales_price) total_sales from 	catalog_sales, 	date_dim,     customer_address,     item where     i_manufact_id        in (select  i_manufact_id from item where i_category in ('Books')) and   cs_item_sk       = i_item_sk and   cs_sold_date_sk     = d_date_sk and   d_year         = 1999 and   d_moy          = 3 and   cs_bill_addr_sk     = ca_address_sk and   ca_gmt_offset      = -5  group by i_manufact_id), ws as ( select      i_manufact_id,sum(ws_ext_sales_price) total_sales from 	web_sales, 	date_dim,     customer_address,     item where     i_manufact_id        in (select  i_manufact_id from item where i_category in ('Books')) and   ws_item_sk       = i_item_sk and   ws_sold_date_sk     = d_date_sk and   d_year         = 1999 and   d_moy          = 3 and   ws_bill_addr_sk     = ca_address_sk and   ca_gmt_offset      = -5 group by i_manufact_id)  select i_manufact_id ,sum(total_sales) total_sales from (select * from ss     union all     select * from cs     union all     select * from ws) tmp1 group by i_manufact_id order by total_sales limit 100) "script_a1b349aeed1c1fc9bc8a3391299fd7a4"
query_34.sql_1   2020-12-12 19:22:28.374   2020-12-12 19:22:28.404             30          12
query_35.sql_1   2020-12-12 19:22:28.404   2020-12-12 19:22:28.405              1               Err     An error has occurred executing the query. Error Message: [SQLITE_ERROR] SQL error or missing database (no such table: web_sales) Query: select count(1) from (select  ca_state,  cd_gender,  cd_marital_status,  cd_dep_count,  count(*) cnt1,  avg(cd_dep_count),  max(cd_dep_count),  sum(cd_dep_count),  cd_dep_employed_count,  count(*) cnt2,  avg(cd_dep_employed_count) as avg_cd_dep_employed_count,  max(cd_dep_employed_count) as max_cd_dep_employed_count,  sum(cd_dep_employed_count) as sum_cd_dep_employed_count,  cd_dep_college_count,  count(*) cnt3,  avg(cd_dep_college_count) as avg_cd_dep_college_count,  max(cd_dep_college_count) as max_cd_dep_college_count,  sum(cd_dep_college_count) as sum_cd_dep_college_count from  customer c,customer_address ca,customer_demographics where  c.c_current_addr_sk = ca.ca_address_sk and  cd_demo_sk = c.c_current_cdemo_sk and  exists (select *      from store_sales,date_dim      where c.c_customer_sk = ss_customer_sk and         ss_sold_date_sk = d_date_sk and         d_year = 1999 and         d_qoy < 4) and  (exists (select *       from web_sales,date_dim       where c.c_customer_sk = ws_bill_customer_sk and          ws_sold_date_sk = d_date_sk and          d_year = 1999 and          d_qoy < 4) or   exists (select *       from catalog_sales,date_dim       where c.c_customer_sk = cs_ship_customer_sk and          cs_sold_date_sk = d_date_sk and          d_year = 1999 and          d_qoy < 4)) group by ca_state,      cd_gender,      cd_marital_status,      cd_dep_count,      cd_dep_employed_count,      cd_dep_college_count order by ca_state,      cd_gender,      cd_marital_status,      cd_dep_count,      cd_dep_employed_count,      cd_dep_college_count limit 100) "script_612ad1c0483a10ac14c3db296cef1cb1"
query_36.sql_1   2020-12-12 19:22:28.405   2020-12-12 19:22:28.462             57         100
query_37.sql_1   2020-12-12 19:22:28.462   2020-12-12 19:22:28.463              1               Err     An error has occurred executing the query. Error Message: [SQLITE_ERROR] SQL error or missing database (no such table: inventory) Query: select count(1) from (select i_item_id    ,i_item_desc    ,i_current_price from item, inventory, date_dim, catalog_sales where i_current_price between 22 and 22 + 30 and inv_item_sk = i_item_sk and d_date_sk=inv_date_sk --and d_date between cast('2001-06-02' as date) and (cast('2001-06-02' as date) + 60 days) and d_date between date('2001-06-02') and date('2001-06-02','+60 days') and i_manufact_id in (942,894,848,848) and inv_quantity_on_hand between 100 and 500 and cs_item_sk = i_item_sk group by i_item_id,i_item_desc,i_current_price order by i_item_id limit 100) "script_57db948451ed9b8ff17817cead29fff0"
query_38.sql_1   2020-12-12 19:22:28.463   2020-12-12 19:22:28.464              1               Err     An error has occurred executing the query. Error Message: [SQLITE_ERROR] SQL error or missing database (no such table: web_sales) Query: select count(1) from (select count(*) from (   select distinct c_last_name, c_first_name, d_date   from store_sales, date_dim, customer      where store_sales.ss_sold_date_sk = date_dim.d_date_sk    and store_sales.ss_customer_sk = customer.c_customer_sk    and d_month_seq between 1212 and 1212 + 11  intersect   select distinct c_last_name, c_first_name, d_date   from catalog_sales, date_dim, customer      where catalog_sales.cs_sold_date_sk = date_dim.d_date_sk    and catalog_sales.cs_bill_customer_sk = customer.c_customer_sk    and d_month_seq between 1212 and 1212 + 11  intersect   select distinct c_last_name, c_first_name, d_date   from web_sales, date_dim, customer      where web_sales.ws_sold_date_sk = date_dim.d_date_sk    and web_sales.ws_bill_customer_sk = customer.c_customer_sk    and d_month_seq between 1212 and 1212 + 11 ) hot_cust limit 100) "script_369651aa02784f91da73c42826cd904e"
query_4.sql_1    2020-12-12 19:22:28.464   2020-12-12 19:22:28.466              2               Err     An error has occurred executing the query. Error Message: [SQLITE_ERROR] SQL error or missing database (no such table: web_sales) Query: select count(1) from (with year_total as ( select c_customer_id customer_id    ,c_first_name customer_first_name    ,c_last_name customer_last_name    ,c_preferred_cust_flag customer_preferred_cust_flag    ,c_birth_country customer_birth_country    ,c_login customer_login    ,c_email_address customer_email_address    ,d_year dyear    ,sum(((ss_ext_list_price-ss_ext_wholesale_cost-ss_ext_discount_amt)+ss_ext_sales_price)/2) year_total    ,'s' sale_type from customer   ,store_sales   ,date_dim where c_customer_sk = ss_customer_sk  and ss_sold_date_sk = d_date_sk group by c_customer_id     ,c_first_name     ,c_last_name     ,c_preferred_cust_flag     ,c_birth_country     ,c_login     ,c_email_address     ,d_year union all select c_customer_id customer_id    ,c_first_name customer_first_name    ,c_last_name customer_last_name    ,c_preferred_cust_flag customer_preferred_cust_flag    ,c_birth_country customer_birth_country    ,c_login customer_login    ,c_email_address customer_email_address    ,d_year dyear    ,sum((((cs_ext_list_price-cs_ext_wholesale_cost-cs_ext_discount_amt)+cs_ext_sales_price)/2) ) year_total    ,'c' sale_type from customer   ,catalog_sales   ,date_dim where c_customer_sk = cs_bill_customer_sk  and cs_sold_date_sk = d_date_sk group by c_customer_id     ,c_first_name     ,c_last_name     ,c_preferred_cust_flag     ,c_birth_country     ,c_login     ,c_email_address     ,d_year union all select c_customer_id customer_id    ,c_first_name customer_first_name    ,c_last_name customer_last_name    ,c_preferred_cust_flag customer_preferred_cust_flag    ,c_birth_country customer_birth_country    ,c_login customer_login    ,c_email_address customer_email_address    ,d_year dyear    ,sum((((ws_ext_list_price-ws_ext_wholesale_cost-ws_ext_discount_amt)+ws_ext_sales_price)/2) ) year_total    ,'w' sale_type from customer   ,web_sales   ,date_dim where c_customer_sk = ws_bill_customer_sk  and ws_sold_date_sk = d_date_sk group by c_customer_id     ,c_first_name     ,c_last_name     ,c_preferred_cust_flag     ,c_birth_country     ,c_login     ,c_email_address     ,d_year     )  select           t_s_secyear.customer_id         ,t_s_secyear.customer_first_name         ,t_s_secyear.customer_last_name         ,t_s_secyear.customer_email_address from year_total t_s_firstyear   ,year_total t_s_secyear   ,year_total t_c_firstyear   ,year_total t_c_secyear   ,year_total t_w_firstyear   ,year_total t_w_secyear where t_s_secyear.customer_id = t_s_firstyear.customer_id  and t_s_firstyear.customer_id = t_c_secyear.customer_id  and t_s_firstyear.customer_id = t_c_firstyear.customer_id  and t_s_firstyear.customer_id = t_w_firstyear.customer_id  and t_s_firstyear.customer_id = t_w_secyear.customer_id  and t_s_firstyear.sale_type = 's'  and t_c_firstyear.sale_type = 'c'  and t_w_firstyear.sale_type = 'w'  and t_s_secyear.sale_type = 's'  and t_c_secyear.sale_type = 'c'  and t_w_secyear.sale_type = 'w'  and t_s_firstyear.dyear = 2001  and t_s_secyear.dyear = 2001+1  and t_c_firstyear.dyear = 2001  and t_c_secyear.dyear = 2001+1  and t_w_firstyear.dyear = 2001  and t_w_secyear.dyear = 2001+1  and t_s_firstyear.year_total > 0  and t_c_firstyear.year_total > 0  and t_w_firstyear.year_total > 0  and case when t_c_firstyear.year_total > 0 then t_c_secyear.year_total / t_c_firstyear.year_total else null end      > case when t_s_firstyear.year_total > 0 then t_s_secyear.year_total / t_s_firstyear.year_total else null end  and case when t_c_firstyear.year_total > 0 then t_c_secyear.year_total / t_c_firstyear.year_total else null end      > case when t_w_firstyear.year_total > 0 then t_w_secyear.year_total / t_w_firstyear.year_total else null end order by t_s_secyear.customer_id     ,t_s_secyear.customer_first_name     ,t_s_secyear.customer_last_name     ,t_s_secyear.customer_email_address limit 100) "script_9fcae8968b2e1c045e9c523d3e6d4619"
query_40.sql_1   2020-12-12 19:22:28.466   2020-12-12 19:22:28.467              1               Err     An error has occurred executing the query. Error Message: [SQLITE_ERROR] SQL error or missing database (no such table: catalog_sales) Query: select count(1) from (select   w_state  ,i_item_id -- ,sum(case when (cast(d_date as date) < cast ('1998-04-08' as date)) -- 		then cs_sales_price - coalesce(cr_refunded_cash,0) else 0 end) as sales_before -- ,sum(case when (cast(d_date as date) >= cast ('1998-04-08' as date)) -- 		then cs_sales_price - coalesce(cr_refunded_cash,0) else 0 end) as sales_after  ,sum(case when date(d_date) < date('1998-04-08')  		then cs_sales_price - coalesce(cr_refunded_cash,0) else 0 end) as sales_before  ,sum(case when date(d_date) >= date('1998-04-08')  		then cs_sales_price - coalesce(cr_refunded_cash,0) else 0 end) as sales_after from  catalog_sales left outer join catalog_returns on    (cs_order_number = cr_order_number     and cs_item_sk = cr_item_sk)  ,warehouse  ,item  ,date_dim where   i_current_price between 0.99 and 1.49 and i_item_sk     = cs_item_sk and cs_warehouse_sk  = w_warehouse_sk  and cs_sold_date_sk  = d_date_sk -- and d_date between (cast ('1998-04-08' as date) - 30 days) --        and (cast ('1998-04-08' as date) + 30 days)  and d_date between date('1998-04-08', '-30 days')         and date('1998-04-08', '+30 days') group by   w_state,i_item_id order by w_state,i_item_id limit 100) "script_47bb05d2e37044c7827782c286181725"
query_41.sql_1   2020-12-12 19:22:28.467   2020-12-12 19:22:28.485             18           0
query_42.sql_1   2020-12-12 19:22:28.485   2020-12-12 19:22:28.521             36           6
query_43.sql_1   2020-12-12 19:22:28.521   2020-12-12 19:22:28.59              69           2
query_44.sql_1   2020-12-12 19:22:28.59    2020-12-12 19:22:29.835           1245          10
query_45.sql_1   2020-12-12 19:22:29.835   2020-12-12 19:22:29.836              1               Err     An error has occurred executing the query. Error Message: [SQLITE_ERROR] SQL error or missing database (no such table: web_sales) Query: select count(1) from (select ca_zip, ca_county, sum(ws_sales_price) from web_sales, customer, customer_address, date_dim, item where ws_bill_customer_sk = c_customer_sk 	and c_current_addr_sk = ca_address_sk  	and ws_item_sk = i_item_sk  	and ( substr(ca_zip,1,5) in ('85669', '86197','88274','83405','86475', '85392', '85460', '80348', '81792') 	   or  	   i_item_id in (select i_item_id               from item               where i_item_sk in (2, 3, 5, 7, 11, 13, 17, 19, 23, 29)               ) 	  ) 	and ws_sold_date_sk = d_date_sk 	and d_qoy = 2 and d_year = 2000 group by ca_zip, ca_county order by ca_zip, ca_county limit 100) "script_d8619545ba829f5d4079873e66fd6229"
query_46.sql_1   2020-12-12 19:22:29.836   2020-12-12 19:22:29.868             32         100
query_47.sql_1   2020-12-12 19:22:29.868   2020-12-12 19:22:30.376            508         100
query_48.sql_1   2020-12-12 19:22:30.376   2020-12-12 19:22:30.416             40           1
query_49.sql_1   2020-12-12 19:22:30.416   2020-12-12 19:22:30.417              1               Err     An error has occurred executing the query. Error Message: [SQLITE_ERROR] SQL error or missing database (no such table: catalog_sales) Query: select count(1) from (select channel, item, return_ratio, return_rank, currency_rank from (select 'web' as channel ,web.item ,web.return_ratio ,web.return_rank ,web.currency_rank from ( 	select  	 item 	,return_ratio 	,currency_ratio 	,rank() over (order by return_ratio) as return_rank 	,rank() over (order by currency_ratio) as currency_rank 	from 	(	select ws.ws_item_sk as item 		,(cast(sum(coalesce(wr.wr_return_quantity,0)) as decimal(15,4))/ 		cast(sum(coalesce(ws.ws_quantity,0)) as decimal(15,4) )) as return_ratio 		,(cast(sum(coalesce(wr.wr_return_amt,0)) as decimal(15,4))/ 		cast(sum(coalesce(ws.ws_net_paid,0)) as decimal(15,4) )) as currency_ratio 		from  		 web_sales ws left outer join web_returns wr  			on (ws.ws_order_number = wr.wr_order_number and  			ws.ws_item_sk = wr.wr_item_sk)         ,date_dim 		where  			wr.wr_return_amt > 10000  			and ws.ws_net_profit > 1             and ws.ws_net_paid > 0             and ws.ws_quantity > 0             and ws_sold_date_sk = d_date_sk             and d_year = 2000             and d_moy = 12 		group by ws.ws_item_sk 	) in_web ) web where  ( web.return_rank <= 10 or web.currency_rank <= 10 ) union select  'catalog' as channel ,catalog.item ,catalog.return_ratio ,catalog.return_rank ,catalog.currency_rank from ( 	select  	 item 	,return_ratio 	,currency_ratio 	,rank() over (order by return_ratio) as return_rank 	,rank() over (order by currency_ratio) as currency_rank 	from 	(	select  		cs.cs_item_sk as item 		,(cast(sum(coalesce(cr.cr_return_quantity,0)) as decimal(15,4))/ 		cast(sum(coalesce(cs.cs_quantity,0)) as decimal(15,4) )) as return_ratio 		,(cast(sum(coalesce(cr.cr_return_amount,0)) as decimal(15,4))/ 		cast(sum(coalesce(cs.cs_net_paid,0)) as decimal(15,4) )) as currency_ratio 		from  		catalog_sales cs left outer join catalog_returns cr 			on (cs.cs_order_number = cr.cr_order_number and  			cs.cs_item_sk = cr.cr_item_sk)         ,date_dim 		where  			cr.cr_return_amount > 10000  			and cs.cs_net_profit > 1             and cs.cs_net_paid > 0             and cs.cs_quantity > 0             and cs_sold_date_sk = d_date_sk             and d_year = 2000             and d_moy = 12         group by cs.cs_item_sk 	) in_cat ) catalog where  ( catalog.return_rank <= 10 or catalog.currency_rank <=10 ) union select  'store' as channel ,store.item ,store.return_ratio ,store.return_rank ,store.currency_rank from ( 	select  	 item 	,return_ratio 	,currency_ratio 	,rank() over (order by return_ratio) as return_rank 	,rank() over (order by currency_ratio) as currency_rank 	from 	(	select sts.ss_item_sk as item 		,(cast(sum(coalesce(sr.sr_return_quantity,0)) as decimal(15,4))/cast(sum(coalesce(sts.ss_quantity,0)) as decimal(15,4) )) as return_ratio 		,(cast(sum(coalesce(sr.sr_return_amt,0)) as decimal(15,4))/cast(sum(coalesce(sts.ss_net_paid,0)) as decimal(15,4) )) as currency_ratio 		from  		store_sales sts left outer join store_returns sr 			on (sts.ss_ticket_number = sr.sr_ticket_number and sts.ss_item_sk = sr.sr_item_sk)         ,date_dim 		where  			sr.sr_return_amt > 10000  			and sts.ss_net_profit > 1             and sts.ss_net_paid > 0              and sts.ss_quantity > 0             and ss_sold_date_sk = d_date_sk             and d_year = 2000             and d_moy = 12 		group by sts.ss_item_sk 	) in_store ) store where ( store.return_rank <= 10 or  store.currency_rank <= 10 ) ) order by 1,4,5,2 limit 100) "script_a24b516cbd818d5e412119bd3b3bd2b7"
query_5.sql_1    2020-12-12 19:22:30.417   2020-12-12 19:22:30.419              2               Err     An error has occurred executing the query. Error Message: [SQLITE_ERROR] SQL error or missing database (no such table: catalog_returns) Query: select count(1) from (with ssr as (select s_store_id,     sum(sales_price) as sales,     sum(profit) as profit,     sum(return_amt) as returns,     sum(net_loss) as profit_loss from  ( select ss_store_sk as store_sk,       ss_sold_date_sk as date_sk,       ss_ext_sales_price as sales_price,       ss_net_profit as profit,       cast(0 as decimal(7,2)) as return_amt,       cast(0 as decimal(7,2)) as net_loss   from store_sales   union all   select sr_store_sk as store_sk,      sr_returned_date_sk as date_sk,      cast(0 as decimal(7,2)) as sales_price,      cast(0 as decimal(7,2)) as profit,      sr_return_amt as return_amt,      sr_net_loss as net_loss   from store_returns  ) salesreturns,   date_dim,   store where date_sk = d_date_sk --    and d_date between cast('1998-08-04' as date) --         and (cast('1998-08-04' as date) + 14 days)    and d_date between date('1998-08-04')    and date('1998-08-04', '+14 days')    and store_sk = s_store_sk group by s_store_id) , csr as (select cp_catalog_page_id,     sum(sales_price) as sales,     sum(profit) as profit,     sum(return_amt) as returns,     sum(net_loss) as profit_loss from  ( select cs_catalog_page_sk as page_sk,       cs_sold_date_sk as date_sk,       cs_ext_sales_price as sales_price,       cs_net_profit as profit,       cast(0 as decimal(7,2)) as return_amt,       cast(0 as decimal(7,2)) as net_loss   from catalog_sales   union all   select cr_catalog_page_sk as page_sk,      cr_returned_date_sk as date_sk,      cast(0 as decimal(7,2)) as sales_price,      cast(0 as decimal(7,2)) as profit,      cr_return_amount as return_amt,      cr_net_loss as net_loss   from catalog_returns  ) salesreturns,   date_dim,   catalog_page where date_sk = d_date_sk --    and d_date between cast('1998-08-04' as date) --         and (cast('1998-08-04' as date) + 14 days)    and d_date between date('1998-08-04')    and date('1998-08-04', '+14 days')    and page_sk = cp_catalog_page_sk group by cp_catalog_page_id) , wsr as (select web_site_id,     sum(sales_price) as sales,     sum(profit) as profit,     sum(return_amt) as returns,     sum(net_loss) as profit_loss from  ( select ws_web_site_sk as wsr_web_site_sk,       ws_sold_date_sk as date_sk,       ws_ext_sales_price as sales_price,       ws_net_profit as profit,       cast(0 as decimal(7,2)) as return_amt,       cast(0 as decimal(7,2)) as net_loss   from web_sales   union all   select ws_web_site_sk as wsr_web_site_sk,      wr_returned_date_sk as date_sk,      cast(0 as decimal(7,2)) as sales_price,      cast(0 as decimal(7,2)) as profit,      wr_return_amt as return_amt,      wr_net_loss as net_loss   from web_returns left outer join web_sales on     ( wr_item_sk = ws_item_sk      and wr_order_number = ws_order_number)  ) salesreturns,   date_dim,   web_site where date_sk = d_date_sk --    and d_date between cast('1998-08-04' as date) --         and (cast('1998-08-04' as date) + 14 days) 	  and d_date between date('1998-08-04')          and date('1998-08-04', '+14 days')    and wsr_web_site_sk = web_site_sk group by web_site_id)  select channel     , id     , sum(sales) as sales     , sum(returns) as returns     , sum(profit) as profit from  (select 'store channel' as channel     , 'store' || s_store_id as id     , sales     , returns     , (profit - profit_loss) as profit from  ssr union all select 'catalog channel' as channel     , 'catalog_page' || cp_catalog_page_id as id     , sales     , returns     , (profit - profit_loss) as profit from csr union all select 'web channel' as channel     , 'web_site' || web_site_id as id     , sales     , returns     , (profit - profit_loss) as profit from  wsr ) x --group by rollup (channel, id) group by channel, id order by channel     ,id limit 100) "script_09a37ad60ea543e4151e16b65a031895"
query_50.sql_1   2020-12-12 19:22:30.419   2020-12-12 19:22:30.478             59           2
query_52.sql_1   2020-12-12 19:22:30.478   2020-12-12 19:22:30.505             27          10
query_53.sql_1   2020-12-12 19:22:30.505   2020-12-12 19:22:30.593             88           0
query_54.sql_1   2020-12-12 19:22:30.594   2020-12-12 19:22:30.594              0               Err     An error has occurred executing the query. Error Message: [SQLITE_ERROR] SQL error or missing database (no such table: web_sales) Query: select count(1) from (with my_customers as ( select distinct c_customer_sk     , c_current_addr_sk from      ( select cs_sold_date_sk sold_date_sk,         cs_bill_customer_sk customer_sk,         cs_item_sk item_sk      from  catalog_sales      union all      select ws_sold_date_sk sold_date_sk,         ws_bill_customer_sk customer_sk,         ws_item_sk item_sk      from  web_sales     ) cs_or_ws_sales,     item,     date_dim,     customer where  sold_date_sk = d_date_sk     and item_sk = i_item_sk     and i_category = 'Jewelry'     and i_class = 'consignment'     and c_customer_sk = cs_or_ws_sales.customer_sk     and d_moy = 3     and d_year = 1999 ) , my_revenue as ( select c_customer_sk,     sum(ss_ext_sales_price) as revenue from  my_customers,     store_sales,     customer_address,     store,     date_dim where c_current_addr_sk = ca_address_sk     and ca_county = s_county     and ca_state = s_state     and ss_sold_date_sk = d_date_sk     and c_customer_sk = ss_customer_sk     and d_month_seq between (select distinct d_month_seq+1                 from  date_dim where d_year = 1999 and d_moy = 3)              and (select distinct d_month_seq+3                 from  date_dim where d_year = 1999 and d_moy = 3) group by c_customer_sk ) , segments as (select cast((revenue/50) as int) as segment  from  my_revenue )  select segment, count(*) as num_customers, segment*50 as segment_base from segments group by segment order by segment, num_customers limit 100) "script_9d93e7a9732db6eadd16d30157c55a90"
query_55.sql_1   2020-12-12 19:22:30.594   2020-12-12 19:22:30.621             27           7
query_56.sql_1   2020-12-12 19:22:30.621   2020-12-12 19:22:30.622              1               Err     An error has occurred executing the query. Error Message: [SQLITE_ERROR] SQL error or missing database (no such table: catalog_sales) Query: select count(1) from (with ss as ( select i_item_id,sum(ss_ext_sales_price) total_sales from 	store_sales, 	date_dim,     customer_address,     item where i_item_id in (select   i_item_id from item where i_color in ('orchid','chiffon','lace')) and   ss_item_sk       = i_item_sk and   ss_sold_date_sk     = d_date_sk and   d_year         = 2000 and   d_moy          = 1 and   ss_addr_sk       = ca_address_sk and   ca_gmt_offset      = -8  group by i_item_id), cs as ( select i_item_id,sum(cs_ext_sales_price) total_sales from 	catalog_sales, 	date_dim,     customer_address,     item where     i_item_id        in (select  i_item_id from item where i_color in ('orchid','chiffon','lace')) and   cs_item_sk       = i_item_sk and   cs_sold_date_sk     = d_date_sk and   d_year         = 2000 and   d_moy          = 1 and   cs_bill_addr_sk     = ca_address_sk and   ca_gmt_offset      = -8  group by i_item_id), ws as ( select i_item_id,sum(ws_ext_sales_price) total_sales from 	web_sales, 	date_dim,     customer_address,     item where     i_item_id        in (select  i_item_id from item where i_color in ('orchid','chiffon','lace')) and   ws_item_sk       = i_item_sk and   ws_sold_date_sk     = d_date_sk and   d_year         = 2000 and   d_moy          = 1 and   ws_bill_addr_sk     = ca_address_sk and   ca_gmt_offset      = -8 group by i_item_id)  select i_item_id ,sum(total_sales) total_sales from (select * from ss     union all     select * from cs     union all     select * from ws) tmp1 group by i_item_id order by total_sales,      i_item_id limit 100) "script_8ca44dc6e79e561c1dd1add9c53cc6c2"
query_57.sql_1   2020-12-12 19:22:30.622   2020-12-12 19:22:30.623              1               Err     An error has occurred executing the query. Error Message: [SQLITE_ERROR] SQL error or missing database (no such table: catalog_sales) Query: select count(1) from (with v1 as( select i_category, i_brand,     cc_name,     d_year, d_moy,     sum(cs_sales_price) sum_sales,     avg(sum(cs_sales_price)) over      (partition by i_category, i_brand,           cc_name, d_year)      avg_monthly_sales,     rank() over      (partition by i_category, i_brand,           cc_name      order by d_year, d_moy) rn from item, catalog_sales, date_dim, call_center where cs_item_sk = i_item_sk and    cs_sold_date_sk = d_date_sk and    cc_call_center_sk= cs_call_center_sk and    (     d_year = 2000 or     ( d_year = 2000-1 and d_moy =12) or     ( d_year = 2000+1 and d_moy =1)    ) group by i_category, i_brand,      cc_name , d_year, d_moy), v2 as( select v1.i_category, v1.i_brand     ,v1.d_year, v1.d_moy     ,v1.avg_monthly_sales     ,v1.sum_sales, v1_lag.sum_sales psum, v1_lead.sum_sales nsum from v1, v1 v1_lag, v1 v1_lead where v1.i_category = v1_lag.i_category and    v1.i_category = v1_lead.i_category and    v1.i_brand = v1_lag.i_brand and    v1.i_brand = v1_lead.i_brand and    v1. cc_name = v1_lag. cc_name and    v1. cc_name = v1_lead. cc_name and    v1.rn = v1_lag.rn + 1 and    v1.rn = v1_lead.rn - 1)  select * from v2 where d_year = 2000 and     avg_monthly_sales > 0 and     case when avg_monthly_sales > 0 then abs(sum_sales - avg_monthly_sales) / avg_monthly_sales else null end > 0.1 order by sum_sales - avg_monthly_sales, 3 limit 100) "script_6eaea3129e1bf47380ab185207494ff2"
query_58.sql_1   2020-12-12 19:22:30.623   2020-12-12 19:22:30.624              1               Err     An error has occurred executing the query. Error Message: [SQLITE_ERROR] SQL error or missing database (no such table: web_sales) Query: select count(1) from (WITH ss_items AS ( 	SELECT 		i_item_id item_id , 		SUM( ss_ext_sales_price ) ss_item_rev 	FROM 		store_sales , 		item , 		date_dim 	WHERE 		ss_item_sk = i_item_sk 		AND d_date IN ( 			SELECT 				d_date 			FROM 				date_dim 			WHERE 				d_week_seq = ( 					SELECT 						d_week_seq 					FROM 						date_dim 					WHERE 						d_date = '1998-02-19' 				) 		) 		AND ss_sold_date_sk = d_date_sk 	GROUP BY 		i_item_id ), cs_items AS ( 	SELECT 		i_item_id item_id , 		SUM( cs_ext_sales_price ) cs_item_rev 	FROM 		catalog_sales , 		item , 		date_dim 	WHERE 		cs_item_sk = i_item_sk 		AND d_date IN ( 			SELECT 				d_date 			FROM 				date_dim 			WHERE 				d_week_seq = ( 					SELECT 						d_week_seq 					FROM 						date_dim 					WHERE 						d_date = '1998-02-19' 				) 		) 		AND cs_sold_date_sk = d_date_sk 	GROUP BY 		i_item_id ), ws_items AS ( 	SELECT 		i_item_id item_id , 		SUM( ws_ext_sales_price ) ws_item_rev 	FROM 		web_sales , 		item , 		date_dim 	WHERE 		ws_item_sk = i_item_sk 		AND d_date IN ( 			SELECT 				d_date 			FROM 				date_dim 			WHERE 				d_week_seq =( 					SELECT 						d_week_seq 					FROM 						date_dim 					WHERE 						d_date = '1998-02-19' 				) 		) 		AND ws_sold_date_sk = d_date_sk 	GROUP BY 		i_item_id ) SELECT 	ss_items.item_id , 	ss_item_rev , 	ss_item_rev /( 		( 			ss_item_rev + cs_item_rev + ws_item_rev 		)/ 3 	) * 100 ss_dev , 	cs_item_rev , 	cs_item_rev /( 		( 			ss_item_rev + cs_item_rev + ws_item_rev 		)/ 3 	) * 100 cs_dev , 	ws_item_rev , 	ws_item_rev /( 		( 			ss_item_rev + cs_item_rev + ws_item_rev 		)/ 3 	) * 100 ws_dev , 	( 		ss_item_rev + cs_item_rev + ws_item_rev 	)/ 3 average FROM 	ss_items, 	cs_items, 	ws_items WHERE 	ss_items.item_id = cs_items.item_id 	AND ss_items.item_id = ws_items.item_id 	AND ss_item_rev BETWEEN 0.9 * cs_item_rev AND 1.1 * cs_item_rev 	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 	ss_items.item_id , 	ss_item_rev LIMIT 100) "script_aa7232b8532c74ed96b31d4884ed7fe9"
query_59.sql_1   2020-12-12 19:22:30.624   2020-12-12 19:22:30.963            339         100
query_6.sql_1    2020-12-12 19:22:30.963   2020-12-12 19:22:31.234            271           3
query_60.sql_1   2020-12-12 19:22:31.234   2020-12-12 19:22:31.235              1               Err     An error has occurred executing the query. Error Message: [SQLITE_ERROR] SQL error or missing database (no such table: catalog_sales) Query: select count(1) from (with ss as ( select      i_item_id,sum(ss_ext_sales_price) total_sales from 	store_sales, 	date_dim,     customer_address,     item where     i_item_id in (select  i_item_id from item where i_category in ('Children')) and   ss_item_sk       = i_item_sk and   ss_sold_date_sk     = d_date_sk and   d_year         = 1999 and   d_moy          = 9 and   ss_addr_sk       = ca_address_sk and   ca_gmt_offset      = -6  group by i_item_id), cs as ( select      i_item_id,sum(cs_ext_sales_price) total_sales from 	catalog_sales, 	date_dim,     customer_address,     item where     i_item_id        in (select  i_item_id from item where i_category in ('Children')) and   cs_item_sk       = i_item_sk and   cs_sold_date_sk     = d_date_sk and   d_year         = 1999 and   d_moy          = 9 and   cs_bill_addr_sk     = ca_address_sk and   ca_gmt_offset      = -6  group by i_item_id), ws as ( select      i_item_id,sum(ws_ext_sales_price) total_sales from 	web_sales, 	date_dim,     customer_address,     item where     i_item_id        in (select  i_item_id from item where i_category in ('Children')) and   ws_item_sk       = i_item_sk and   ws_sold_date_sk     = d_date_sk and   d_year         = 1999 and   d_moy          = 9 and   ws_bill_addr_sk     = ca_address_sk and   ca_gmt_offset      = -6 group by i_item_id)  select   i_item_id ,sum(total_sales) total_sales from (select * from ss     union all     select * from cs     union all     select * from ws) tmp1 group by i_item_id order by i_item_id    ,total_sales limit 100) "script_cf29b8739fa19175b1fd8b8d1186e127"
query_61.sql_1   2020-12-12 19:22:31.235   2020-12-12 19:22:31.28              45           1
query_62.sql_1   2020-12-12 19:22:31.28    2020-12-12 19:22:31.28               0               Err     An error has occurred executing the query. Error Message: [SQLITE_ERROR] SQL error or missing database (no such table: web_sales) Query: select count(1) from (select   substr(w_warehouse_name,1,20)  ,sm_type  ,web_name  ,sum(case when (ws_ship_date_sk - ws_sold_date_sk <= 30 ) then 1 else 0 end) as "30 days"  ,sum(case when (ws_ship_date_sk - ws_sold_date_sk > 30) and          (ws_ship_date_sk - ws_sold_date_sk <= 60) then 1 else 0 end ) as "31-60 days"  ,sum(case when (ws_ship_date_sk - ws_sold_date_sk > 60) and          (ws_ship_date_sk - ws_sold_date_sk <= 90) then 1 else 0 end) as "61-90 days"  ,sum(case when (ws_ship_date_sk - ws_sold_date_sk > 90) and         (ws_ship_date_sk - ws_sold_date_sk <= 120) then 1 else 0 end) as "91-120 days"  ,sum(case when (ws_ship_date_sk - ws_sold_date_sk > 120) then 1 else 0 end) as ">120 days" from  web_sales  ,warehouse  ,ship_mode  ,web_site  ,date_dim where   d_month_seq between 1212 and 1212 + 11 and ws_ship_date_sk  = d_date_sk and ws_warehouse_sk  = w_warehouse_sk and ws_ship_mode_sk  = sm_ship_mode_sk and ws_web_site_sk  = web_site_sk group by  substr(w_warehouse_name,1,20)  ,sm_type  ,web_name order by substr(w_warehouse_name,1,20)     ,sm_type    ,web_name limit 100) "script_045c66089727bf37b251472f03d6991c"
query_63.sql_1   2020-12-12 19:22:31.28    2020-12-12 19:22:31.364             84           0
query_64.sql_1   2020-12-12 19:22:31.364   2020-12-12 19:22:31.366              2               Err     An error has occurred executing the query. Error Message: [SQLITE_ERROR] SQL error or missing database (no such table: catalog_sales) Query: select count(1) from (with cs_ui as (select cs_item_sk     ,sum(cs_ext_list_price) as sale,sum(cr_refunded_cash+cr_reversed_charge+cr_store_credit) as refund  from catalog_sales    ,catalog_returns  where cs_item_sk = cr_item_sk   and cs_order_number = cr_order_number  group by cs_item_sk  having sum(cs_ext_list_price)>2*sum(cr_refunded_cash+cr_reversed_charge+cr_store_credit)), cross_sales as (select i_product_name product_name   ,i_item_sk item_sk   ,s_store_name store_name   ,s_zip store_zip   ,ad1.ca_street_number b_street_number   ,ad1.ca_street_name b_street_name   ,ad1.ca_city b_city   ,ad1.ca_zip b_zip   ,ad2.ca_street_number c_street_number   ,ad2.ca_street_name c_street_name   ,ad2.ca_city c_city   ,ad2.ca_zip c_zip   ,d1.d_year as syear   ,d2.d_year as fsyear   ,d3.d_year s2year   ,count(*) cnt   ,sum(ss_wholesale_cost) s1   ,sum(ss_list_price) s2   ,sum(ss_coupon_amt) s3  FROM  store_sales     ,store_returns     ,cs_ui     ,date_dim d1     ,date_dim d2     ,date_dim d3     ,store     ,customer     ,customer_demographics cd1     ,customer_demographics cd2     ,promotion     ,household_demographics hd1     ,household_demographics hd2     ,customer_address ad1     ,customer_address ad2     ,income_band ib1     ,income_band ib2     ,item  WHERE ss_store_sk = s_store_sk AND     ss_sold_date_sk = d1.d_date_sk AND     ss_customer_sk = c_customer_sk AND     ss_cdemo_sk= cd1.cd_demo_sk AND     ss_hdemo_sk = hd1.hd_demo_sk AND     ss_addr_sk = ad1.ca_address_sk and     ss_item_sk = i_item_sk and     ss_item_sk = sr_item_sk and     ss_ticket_number = sr_ticket_number and     ss_item_sk = cs_ui.cs_item_sk and     c_current_cdemo_sk = cd2.cd_demo_sk AND     c_current_hdemo_sk = hd2.hd_demo_sk AND     c_current_addr_sk = ad2.ca_address_sk and     c_first_sales_date_sk = d2.d_date_sk and     c_first_shipto_date_sk = d3.d_date_sk and     ss_promo_sk = p_promo_sk and     hd1.hd_income_band_sk = ib1.ib_income_band_sk and     hd2.hd_income_band_sk = ib2.ib_income_band_sk and     cd1.cd_marital_status <> cd2.cd_marital_status and     i_color in ('maroon','burnished','dim','steel','navajo','chocolate') and     i_current_price between 35 and 35 + 10 and     i_current_price between 35 + 1 and 35 + 15 group by i_product_name    ,i_item_sk    ,s_store_name    ,s_zip    ,ad1.ca_street_number    ,ad1.ca_street_name    ,ad1.ca_city    ,ad1.ca_zip    ,ad2.ca_street_number    ,ad2.ca_street_name    ,ad2.ca_city    ,ad2.ca_zip    ,d1.d_year    ,d2.d_year    ,d3.d_year ) select cs1.product_name   ,cs1.store_name   ,cs1.store_zip   ,cs1.b_street_number   ,cs1.b_street_name   ,cs1.b_city   ,cs1.b_zip   ,cs1.c_street_number   ,cs1.c_street_name   ,cs1.c_city   ,cs1.c_zip   ,cs1.syear   ,cs1.cnt   ,cs1.s1 as s11   ,cs1.s2 as s21   ,cs1.s3 as s31   ,cs2.s1 as s12   ,cs2.s2 as s22   ,cs2.s3 as s32   ,cs2.syear   ,cs2.cnt from cross_sales cs1,cross_sales cs2 where cs1.item_sk=cs2.item_sk and   cs1.syear = 2000 and   cs2.syear = 2000 + 1 and   cs2.cnt <= cs1.cnt and   cs1.store_name = cs2.store_name and   cs1.store_zip = cs2.store_zip order by cs1.product_name    ,cs1.store_name    ,cs2.cnt    ,cs1.s1    ,cs2.s1) "script_676e9d9679b9250e4646ab5bbd7361c8"
query_65.sql_1   2020-12-12 19:22:31.366   2020-12-12 19:22:31.439             73           4
query_66.sql_1   2020-12-12 19:22:31.439   2020-12-12 19:22:31.441              2               Err     An error has occurred executing the query. Error Message: [SQLITE_ERROR] SQL error or missing database (no such table: catalog_sales) Query: select count(1) from (select       w_warehouse_name 	,w_warehouse_sq_ft 	,w_city 	,w_county 	,w_state 	,w_country     ,ship_carriers     ,year 	,sum(jan_sales) as jan_sales 	,sum(feb_sales) as feb_sales 	,sum(mar_sales) as mar_sales 	,sum(apr_sales) as apr_sales 	,sum(may_sales) as may_sales 	,sum(jun_sales) as jun_sales 	,sum(jul_sales) as jul_sales 	,sum(aug_sales) as aug_sales 	,sum(sep_sales) as sep_sales 	,sum(oct_sales) as oct_sales 	,sum(nov_sales) as nov_sales 	,sum(dec_sales) as dec_sales 	,sum(jan_sales/w_warehouse_sq_ft) as jan_sales_per_sq_foot 	,sum(feb_sales/w_warehouse_sq_ft) as feb_sales_per_sq_foot 	,sum(mar_sales/w_warehouse_sq_ft) as mar_sales_per_sq_foot 	,sum(apr_sales/w_warehouse_sq_ft) as apr_sales_per_sq_foot 	,sum(may_sales/w_warehouse_sq_ft) as may_sales_per_sq_foot 	,sum(jun_sales/w_warehouse_sq_ft) as jun_sales_per_sq_foot 	,sum(jul_sales/w_warehouse_sq_ft) as jul_sales_per_sq_foot 	,sum(aug_sales/w_warehouse_sq_ft) as aug_sales_per_sq_foot 	,sum(sep_sales/w_warehouse_sq_ft) as sep_sales_per_sq_foot 	,sum(oct_sales/w_warehouse_sq_ft) as oct_sales_per_sq_foot 	,sum(nov_sales/w_warehouse_sq_ft) as nov_sales_per_sq_foot 	,sum(dec_sales/w_warehouse_sq_ft) as dec_sales_per_sq_foot 	,sum(jan_net) as jan_net 	,sum(feb_net) as feb_net 	,sum(mar_net) as mar_net 	,sum(apr_net) as apr_net 	,sum(may_net) as may_net 	,sum(jun_net) as jun_net 	,sum(jul_net) as jul_net 	,sum(aug_net) as aug_net 	,sum(sep_net) as sep_net 	,sum(oct_net) as oct_net 	,sum(nov_net) as nov_net 	,sum(dec_net) as dec_net from (   select  	w_warehouse_name 	,w_warehouse_sq_ft 	,w_city 	,w_county 	,w_state 	,w_country 	,'DIAMOND' || ',' || 'AIRBORNE' as ship_carriers    ,d_year as year 	,sum(case when d_moy = 1  		then ws_sales_price* ws_quantity else 0 end) as jan_sales 	,sum(case when d_moy = 2  		then ws_sales_price* ws_quantity else 0 end) as feb_sales 	,sum(case when d_moy = 3  		then ws_sales_price* ws_quantity else 0 end) as mar_sales 	,sum(case when d_moy = 4  		then ws_sales_price* ws_quantity else 0 end) as apr_sales 	,sum(case when d_moy = 5  		then ws_sales_price* ws_quantity else 0 end) as may_sales 	,sum(case when d_moy = 6  		then ws_sales_price* ws_quantity else 0 end) as jun_sales 	,sum(case when d_moy = 7  		then ws_sales_price* ws_quantity else 0 end) as jul_sales 	,sum(case when d_moy = 8  		then ws_sales_price* ws_quantity else 0 end) as aug_sales 	,sum(case when d_moy = 9  		then ws_sales_price* ws_quantity else 0 end) as sep_sales 	,sum(case when d_moy = 10  		then ws_sales_price* ws_quantity else 0 end) as oct_sales 	,sum(case when d_moy = 11 		then ws_sales_price* ws_quantity else 0 end) as nov_sales 	,sum(case when d_moy = 12 		then ws_sales_price* ws_quantity else 0 end) as dec_sales 	,sum(case when d_moy = 1  		then ws_net_paid_inc_tax * ws_quantity else 0 end) as jan_net 	,sum(case when d_moy = 2 		then ws_net_paid_inc_tax * ws_quantity else 0 end) as feb_net 	,sum(case when d_moy = 3  		then ws_net_paid_inc_tax * ws_quantity else 0 end) as mar_net 	,sum(case when d_moy = 4  		then ws_net_paid_inc_tax * ws_quantity else 0 end) as apr_net 	,sum(case when d_moy = 5  		then ws_net_paid_inc_tax * ws_quantity else 0 end) as may_net 	,sum(case when d_moy = 6  		then ws_net_paid_inc_tax * ws_quantity else 0 end) as jun_net 	,sum(case when d_moy = 7  		then ws_net_paid_inc_tax * ws_quantity else 0 end) as jul_net 	,sum(case when d_moy = 8  		then ws_net_paid_inc_tax * ws_quantity else 0 end) as aug_net 	,sum(case when d_moy = 9  		then ws_net_paid_inc_tax * ws_quantity else 0 end) as sep_net 	,sum(case when d_moy = 10  		then ws_net_paid_inc_tax * ws_quantity else 0 end) as oct_net 	,sum(case when d_moy = 11 		then ws_net_paid_inc_tax * ws_quantity else 0 end) as nov_net 	,sum(case when d_moy = 12 		then ws_net_paid_inc_tax * ws_quantity else 0 end) as dec_net   from      web_sales     ,warehouse     ,date_dim     ,time_dim 	 ,ship_mode   where       ws_warehouse_sk = w_warehouse_sk     and ws_sold_date_sk = d_date_sk     and ws_sold_time_sk = t_time_sk 	and ws_ship_mode_sk = sm_ship_mode_sk     and d_year = 2002 	and t_time between 49530 and 49530+28800  	and sm_carrier in ('DIAMOND','AIRBORNE')   group by     w_warehouse_name 	,w_warehouse_sq_ft 	,w_city 	,w_county 	,w_state 	,w_country    ,d_year union all   select  	w_warehouse_name 	,w_warehouse_sq_ft 	,w_city 	,w_county 	,w_state 	,w_country 	,'DIAMOND' || ',' || 'AIRBORNE' as ship_carriers    ,d_year as year 	,sum(case when d_moy = 1  		then cs_ext_sales_price* cs_quantity else 0 end) as jan_sales 	,sum(case when d_moy = 2  		then cs_ext_sales_price* cs_quantity else 0 end) as feb_sales 	,sum(case when d_moy = 3  		then cs_ext_sales_price* cs_quantity else 0 end) as mar_sales 	,sum(case when d_moy = 4  		then cs_ext_sales_price* cs_quantity else 0 end) as apr_sales 	,sum(case when d_moy = 5  		then cs_ext_sales_price* cs_quantity else 0 end) as may_sales 	,sum(case when d_moy = 6  		then cs_ext_sales_price* cs_quantity else 0 end) as jun_sales 	,sum(case when d_moy = 7  		then cs_ext_sales_price* cs_quantity else 0 end) as jul_sales 	,sum(case when d_moy = 8  		then cs_ext_sales_price* cs_quantity else 0 end) as aug_sales 	,sum(case when d_moy = 9  		then cs_ext_sales_price* cs_quantity else 0 end) as sep_sales 	,sum(case when d_moy = 10  		then cs_ext_sales_price* cs_quantity else 0 end) as oct_sales 	,sum(case when d_moy = 11 		then cs_ext_sales_price* cs_quantity else 0 end) as nov_sales 	,sum(case when d_moy = 12 		then cs_ext_sales_price* cs_quantity else 0 end) as dec_sales 	,sum(case when d_moy = 1  		then cs_net_paid_inc_ship_tax * cs_quantity else 0 end) as jan_net 	,sum(case when d_moy = 2  		then cs_net_paid_inc_ship_tax * cs_quantity else 0 end) as feb_net 	,sum(case when d_moy = 3  		then cs_net_paid_inc_ship_tax * cs_quantity else 0 end) as mar_net 	,sum(case when d_moy = 4  		then cs_net_paid_inc_ship_tax * cs_quantity else 0 end) as apr_net 	,sum(case when d_moy = 5  		then cs_net_paid_inc_ship_tax * cs_quantity else 0 end) as may_net 	,sum(case when d_moy = 6  		then cs_net_paid_inc_ship_tax * cs_quantity else 0 end) as jun_net 	,sum(case when d_moy = 7  		then cs_net_paid_inc_ship_tax * cs_quantity else 0 end) as jul_net 	,sum(case when d_moy = 8  		then cs_net_paid_inc_ship_tax * cs_quantity else 0 end) as aug_net 	,sum(case when d_moy = 9  		then cs_net_paid_inc_ship_tax * cs_quantity else 0 end) as sep_net 	,sum(case when d_moy = 10  		then cs_net_paid_inc_ship_tax * cs_quantity else 0 end) as oct_net 	,sum(case when d_moy = 11 		then cs_net_paid_inc_ship_tax * cs_quantity else 0 end) as nov_net 	,sum(case when d_moy = 12 		then cs_net_paid_inc_ship_tax * cs_quantity else 0 end) as dec_net   from      catalog_sales     ,warehouse     ,date_dim     ,time_dim 	 ,ship_mode   where       cs_warehouse_sk = w_warehouse_sk     and cs_sold_date_sk = d_date_sk     and cs_sold_time_sk = t_time_sk 	and cs_ship_mode_sk = sm_ship_mode_sk     and d_year = 2002 	and t_time between 49530 AND 49530+28800  	and sm_carrier in ('DIAMOND','AIRBORNE')   group by     w_warehouse_name 	,w_warehouse_sq_ft 	,w_city 	,w_county 	,w_state 	,w_country    ,d_year ) x group by     w_warehouse_name 	,w_warehouse_sq_ft 	,w_city 	,w_county 	,w_state 	,w_country 	,ship_carriers    ,year order by w_warehouse_name limit 100) "script_f7e5f6745de20a7362645aa2de41791d"
query_67.sql_1   2020-12-12 19:22:31.441   2020-12-12 19:22:31.57             129         100
query_68.sql_1   2020-12-12 19:22:31.57    2020-12-12 19:22:31.6               30          79
query_69.sql_1   2020-12-12 19:22:31.6     2020-12-12 19:22:31.602              2               Err     An error has occurred executing the query. Error Message: [SQLITE_ERROR] SQL error or missing database (no such table: web_sales) Query: select count(1) from (select   cd_gender,  cd_marital_status,  cd_education_status,  count(*) cnt1,  cd_purchase_estimate,  count(*) cnt2,  cd_credit_rating,  count(*) cnt3 from  customer c,customer_address ca,customer_demographics where  c.c_current_addr_sk = ca.ca_address_sk and  ca_state in ('CO','IL','MN') and  cd_demo_sk = c.c_current_cdemo_sk and  exists (select *      from store_sales,date_dim      where c.c_customer_sk = ss_customer_sk and         ss_sold_date_sk = d_date_sk and         d_year = 1999 and         d_moy between 1 and 1+2) and  (not exists (select *       from web_sales,date_dim       where c.c_customer_sk = ws_bill_customer_sk and          ws_sold_date_sk = d_date_sk and          d_year = 1999 and          d_moy between 1 and 1+2) and   not exists (select *       from catalog_sales,date_dim       where c.c_customer_sk = cs_ship_customer_sk and          cs_sold_date_sk = d_date_sk and          d_year = 1999 and          d_moy between 1 and 1+2)) group by cd_gender,      cd_marital_status,      cd_education_status,      cd_purchase_estimate,      cd_credit_rating order by cd_gender,      cd_marital_status,      cd_education_status,      cd_purchase_estimate,      cd_credit_rating limit 100) "script_869821a314e36be0842b1ca0af643b34"
query_7.sql_1    2020-12-12 19:22:31.602   2020-12-12 19:22:31.705            103         100
query_70.sql_1   2020-12-12 19:22:31.705   2020-12-12 19:22:31.778             73           1
query_71.sql_1   2020-12-12 19:22:31.778   2020-12-12 19:22:31.778              0               Err     An error has occurred executing the query. Error Message: [SQLITE_ERROR] SQL error or missing database (no such table: catalog_sales) Query: select count(1) from (select i_brand_id brand_id, i_brand brand,t_hour,t_minute, 	sum(ext_price) ext_price from item, (select ws_ext_sales_price as ext_price,             ws_sold_date_sk as sold_date_sk,             ws_item_sk as sold_item_sk,             ws_sold_time_sk as time_sk          from web_sales,date_dim         where d_date_sk = ws_sold_date_sk          and d_moy=12          and d_year=2000         union all         select cs_ext_sales_price as ext_price,             cs_sold_date_sk as sold_date_sk,             cs_item_sk as sold_item_sk,             cs_sold_time_sk as time_sk         from catalog_sales,date_dim         where d_date_sk = cs_sold_date_sk          and d_moy=12          and d_year=2000         union all         select ss_ext_sales_price as ext_price,             ss_sold_date_sk as sold_date_sk,             ss_item_sk as sold_item_sk,             ss_sold_time_sk as time_sk         from store_sales,date_dim         where d_date_sk = ss_sold_date_sk          and d_moy=12          and d_year=2000         ) tmp,time_dim where  sold_item_sk = i_item_sk  and i_manager_id=1  and time_sk = t_time_sk  and (t_meal_time = 'breakfast' or t_meal_time = 'dinner') group by i_brand, i_brand_id,t_hour,t_minute order by ext_price desc, i_brand_id) "script_9b52029538fd4402ebe8b49e222d8737"
query_72.sql_1   2020-12-12 19:22:31.778   2020-12-12 19:22:31.779              1               Err     An error has occurred executing the query. Error Message: [SQLITE_ERROR] SQL error or missing database (no such table: catalog_sales) Query: select count(1) from (select i_item_desc    ,w_warehouse_name    ,d1.d_week_seq    ,sum(case when p_promo_sk is null then 1 else 0 end) no_promo    ,sum(case when p_promo_sk is not null then 1 else 0 end) promo    ,count(*) total_cnt from catalog_sales join inventory on (cs_item_sk = inv_item_sk) join warehouse on (w_warehouse_sk=inv_warehouse_sk) join item on (i_item_sk = cs_item_sk) join customer_demographics on (cs_bill_cdemo_sk = cd_demo_sk) join household_demographics on (cs_bill_hdemo_sk = hd_demo_sk) join date_dim d1 on (cs_sold_date_sk = d1.d_date_sk) join date_dim d2 on (inv_date_sk = d2.d_date_sk) join date_dim d3 on (cs_ship_date_sk = d3.d_date_sk) left outer join promotion on (cs_promo_sk=p_promo_sk) left outer join catalog_returns on (cr_item_sk = cs_item_sk and cr_order_number = cs_order_number) where d1.d_week_seq = d2.d_week_seq  and inv_quantity_on_hand < cs_quantity  and d3.d_date > d1.d_date + 5  and hd_buy_potential = '1001-5000'  and d1.d_year = 2001  and cd_marital_status = 'M' group by i_item_desc,w_warehouse_name,d1.d_week_seq order by total_cnt desc, i_item_desc, w_warehouse_name, d1.d_week_seq limit 100) "script_f71e3922eb681e1d0e555671ab9b33d2"
query_73.sql_1   2020-12-12 19:22:31.779   2020-12-12 19:22:31.805             26           0
query_74.sql_1   2020-12-12 19:22:31.805   2020-12-12 19:22:31.806              1               Err     An error has occurred executing the query. Error Message: [SQLITE_ERROR] SQL error or missing database (no such table: web_sales) Query: select count(1) from (with year_total as ( select c_customer_id customer_id    ,c_first_name customer_first_name    ,c_last_name customer_last_name    ,d_year as year    ,max(ss_net_paid) year_total    ,'s' sale_type from customer   ,store_sales   ,date_dim where c_customer_sk = ss_customer_sk  and ss_sold_date_sk = d_date_sk  and d_year in (2001,2001+1) group by c_customer_id     ,c_first_name     ,c_last_name     ,d_year union all select c_customer_id customer_id    ,c_first_name customer_first_name    ,c_last_name customer_last_name    ,d_year as year    ,max(ws_net_paid) year_total    ,'w' sale_type from customer   ,web_sales   ,date_dim where c_customer_sk = ws_bill_customer_sk  and ws_sold_date_sk = d_date_sk  and d_year in (2001,2001+1) group by c_customer_id     ,c_first_name     ,c_last_name     ,d_year     )  select     t_s_secyear.customer_id, t_s_secyear.customer_first_name, t_s_secyear.customer_last_name from year_total t_s_firstyear   ,year_total t_s_secyear   ,year_total t_w_firstyear   ,year_total t_w_secyear where t_s_secyear.customer_id = t_s_firstyear.customer_id     and t_s_firstyear.customer_id = t_w_secyear.customer_id     and t_s_firstyear.customer_id = t_w_firstyear.customer_id     and t_s_firstyear.sale_type = 's'     and t_w_firstyear.sale_type = 'w'     and t_s_secyear.sale_type = 's'     and t_w_secyear.sale_type = 'w'     and t_s_firstyear.year = 2001     and t_s_secyear.year = 2001+1     and t_w_firstyear.year = 2001     and t_w_secyear.year = 2001+1     and t_s_firstyear.year_total > 0     and t_w_firstyear.year_total > 0     and case when t_w_firstyear.year_total > 0 then t_w_secyear.year_total / t_w_firstyear.year_total else null end      > case when t_s_firstyear.year_total > 0 then t_s_secyear.year_total / t_s_firstyear.year_total else null end order by 2,1,3 limit 100) "script_bb54c455ed1d35d580c2fcfbc4a74797"
query_75.sql_1   2020-12-12 19:22:31.806   2020-12-12 19:22:31.807              1               Err     An error has occurred executing the query. Error Message: [SQLITE_ERROR] SQL error or missing database (no such table: web_sales) Query: select count(1) from (WITH all_sales AS ( SELECT d_year    ,i_brand_id    ,i_class_id    ,i_category_id    ,i_manufact_id    ,SUM(sales_cnt) AS sales_cnt    ,SUM(sales_amt) AS sales_amt FROM (SELECT d_year       ,i_brand_id       ,i_class_id       ,i_category_id       ,i_manufact_id       ,cs_quantity - COALESCE(cr_return_quantity,0) AS sales_cnt       ,cs_ext_sales_price - COALESCE(cr_return_amount,0.0) AS sales_amt    FROM catalog_sales JOIN item ON i_item_sk=cs_item_sk              JOIN date_dim ON d_date_sk=cs_sold_date_sk              LEFT JOIN catalog_returns ON (cs_order_number=cr_order_number                           AND cs_item_sk=cr_item_sk)    WHERE i_category='Sports'    UNION    SELECT d_year       ,i_brand_id       ,i_class_id       ,i_category_id       ,i_manufact_id       ,ss_quantity - COALESCE(sr_return_quantity,0) AS sales_cnt       ,ss_ext_sales_price - COALESCE(sr_return_amt,0.0) AS sales_amt    FROM store_sales JOIN item ON i_item_sk=ss_item_sk             JOIN date_dim ON d_date_sk=ss_sold_date_sk             LEFT JOIN store_returns ON (ss_ticket_number=sr_ticket_number                         AND ss_item_sk=sr_item_sk)    WHERE i_category='Sports'    UNION    SELECT d_year       ,i_brand_id       ,i_class_id       ,i_category_id       ,i_manufact_id       ,ws_quantity - COALESCE(wr_return_quantity,0) AS sales_cnt       ,ws_ext_sales_price - COALESCE(wr_return_amt,0.0) AS sales_amt    FROM web_sales JOIN item ON i_item_sk=ws_item_sk            JOIN date_dim ON d_date_sk=ws_sold_date_sk            LEFT JOIN web_returns ON (ws_order_number=wr_order_number                       AND ws_item_sk=wr_item_sk)    WHERE i_category='Sports') sales_detail GROUP BY d_year, i_brand_id, i_class_id, i_category_id, i_manufact_id) SELECT prev_yr.d_year AS prev_year              ,curr_yr.d_year AS year              ,curr_yr.i_brand_id              ,curr_yr.i_class_id              ,curr_yr.i_category_id              ,curr_yr.i_manufact_id              ,prev_yr.sales_cnt AS prev_yr_cnt              ,curr_yr.sales_cnt AS curr_yr_cnt              ,curr_yr.sales_cnt-prev_yr.sales_cnt AS sales_cnt_diff              ,curr_yr.sales_amt-prev_yr.sales_amt AS sales_amt_diff FROM all_sales curr_yr, all_sales prev_yr WHERE curr_yr.i_brand_id=prev_yr.i_brand_id  AND curr_yr.i_class_id=prev_yr.i_class_id  AND curr_yr.i_category_id=prev_yr.i_category_id  AND curr_yr.i_manufact_id=prev_yr.i_manufact_id  AND curr_yr.d_year=2002  AND prev_yr.d_year=2002-1  AND CAST(curr_yr.sales_cnt AS DECIMAL(17,2))/CAST(prev_yr.sales_cnt AS DECIMAL(17,2))<0.9 ORDER BY sales_cnt_diff,sales_amt_diff limit 100) "script_ddf26b5ea96fc02def05eb6ec282a23d"
query_76.sql_1   2020-12-12 19:22:31.807   2020-12-12 19:22:31.808              1               Err     An error has occurred executing the query. Error Message: [SQLITE_ERROR] SQL error or missing database (no such table: catalog_sales) Query: select count(1) from (select channel, col_name, d_year, d_qoy, i_category, COUNT(*) sales_cnt, SUM(ext_sales_price) sales_amt FROM (     SELECT 'store' as channel, 'ss_addr_sk' col_name, d_year, d_qoy, i_category, ss_ext_sales_price ext_sales_price     FROM store_sales, item, date_dim     WHERE ss_addr_sk IS NULL      AND ss_sold_date_sk=d_date_sk      AND ss_item_sk=i_item_sk     UNION ALL     SELECT 'web' as channel, 'ws_web_page_sk' col_name, d_year, d_qoy, i_category, ws_ext_sales_price ext_sales_price     FROM web_sales, item, date_dim     WHERE ws_web_page_sk IS NULL      AND ws_sold_date_sk=d_date_sk      AND ws_item_sk=i_item_sk     UNION ALL     SELECT 'catalog' as channel, 'cs_warehouse_sk' col_name, d_year, d_qoy, i_category, cs_ext_sales_price ext_sales_price     FROM catalog_sales, item, date_dim     WHERE cs_warehouse_sk IS NULL      AND cs_sold_date_sk=d_date_sk      AND cs_item_sk=i_item_sk) foo GROUP BY channel, col_name, d_year, d_qoy, i_category ORDER BY channel, col_name, d_year, d_qoy, i_category limit 100) "script_287012420ee97042688e9ecd50575741"
query_77.sql_1   2020-12-12 19:22:31.808   2020-12-12 19:22:31.809              1               Err     An error has occurred executing the query. Error Message: [SQLITE_ERROR] SQL error or missing database (no such table: catalog_returns) Query: select count(1) from (WITH ss AS ( 	SELECT 		s_store_sk, 		SUM(ss_ext_sales_price) AS sales, 		SUM(ss_net_profit) AS profit 	FROM 		store_sales, 		date_dim, 		store 	WHERE 		ss_sold_date_sk = d_date_sk 		--    and d_date between cast('1998-08-04' as date) 		--         and (cast('1998-08-04' as date) + 30 days) 		AND d_date BETWEEN DATE('1998-08-04') AND DATE( 			'1998-08-04', 			'+30 days' 		) 		AND ss_store_sk = s_store_sk 	GROUP BY 		s_store_sk ) , sr AS ( 	SELECT 		s_store_sk, 		SUM(sr_return_amt) AS RETURNS, 		SUM(sr_net_loss) AS profit_loss 	FROM 		store_returns, 		date_dim, 		store 	WHERE 		sr_returned_date_sk = d_date_sk 		--    and d_date between cast('1998-08-04' as date) 		--         and (cast('1998-08-04' as date) + 30 days) 		AND d_date BETWEEN DATE('1998-08-04') AND DATE( 			'1998-08-04', 			'+30 days' 		) 		AND sr_store_sk = s_store_sk 	GROUP BY 		s_store_sk ), cs AS ( 	SELECT 		cs_call_center_sk, 		SUM(cs_ext_sales_price) AS sales, 		SUM(cs_net_profit) AS profit 	FROM 		catalog_sales, 		date_dim 	WHERE 		cs_sold_date_sk = d_date_sk 		--    and d_date between cast('1998-08-04' as date) 		--         and (cast('1998-08-04' as date) + 30 days) 		AND d_date BETWEEN DATE('1998-08-04') AND DATE( 			'1998-08-04', 			'+30 days' 		) 	GROUP BY 		cs_call_center_sk ), cr AS ( 	SELECT 		cr_call_center_sk, 		SUM(cr_return_amount) AS RETURNS, 		SUM(cr_net_loss) AS profit_loss 	FROM 		catalog_returns, 		date_dim 	WHERE 		cr_returned_date_sk = d_date_sk --		AND d_date BETWEEN CAST( --			'1998-08-04' AS DATE --		) AND ( --			CAST( --				'1998-08-04' AS DATE --			) + 30 days --		) and d_date between date('1998-08-04')          and date('1998-08-04', '+30 days') 	GROUP BY 		cr_call_center_sk ), ws AS ( 	SELECT 		wp_web_page_sk, 		SUM(ws_ext_sales_price) AS sales, 		SUM(ws_net_profit) AS profit 	FROM 		web_sales, 		date_dim, 		web_page 	WHERE 		ws_sold_date_sk = d_date_sk --		AND d_date BETWEEN CAST( --			'1998-08-04' AS DATE --		) AND ( --			CAST( --				'1998-08-04' AS DATE --			) + 30 days --		) and d_date between date('1998-08-04')          and date('1998-08-04', '+30 days') 		AND ws_web_page_sk = wp_web_page_sk 	GROUP BY 		wp_web_page_sk ), wr AS ( 	SELECT 		wp_web_page_sk, 		SUM(wr_return_amt) AS RETURNS, 		SUM(wr_net_loss) AS profit_loss 	FROM 		web_returns, 		date_dim, 		web_page 	WHERE 		wr_returned_date_sk = d_date_sk --		AND d_date BETWEEN CAST( --			'1998-08-04' AS DATE --		) AND ( --			CAST( --				'1998-08-04' AS DATE --			) + 30 days --		) and d_date between date('1998-08-04')          and date('1998-08-04', '+30 days') 		AND wr_web_page_sk = wp_web_page_sk 	GROUP BY 		wp_web_page_sk ) SELECT 	channel , 	id , 	SUM(sales) AS sales , 	SUM(RETURNS) AS RETURNS , 	SUM(profit) AS profit FROM 	( 		SELECT 			'store channel' AS channel , 			ss.s_store_sk AS id , 			sales , 			COALESCE( 				RETURNS, 				0 			) AS RETURNS , 			( 				profit - COALESCE( 					profit_loss, 					0 				) 			) AS profit 		FROM 			ss 		LEFT JOIN sr ON 			ss.s_store_sk = sr.s_store_sk 	UNION ALL SELECT 			'catalog channel' AS channel , 			cs_call_center_sk AS id , 			sales , 			RETURNS , 			( 				profit - profit_loss 			) AS profit 		FROM 			cs , 			cr 	UNION ALL SELECT 			'web channel' AS channel , 			ws.wp_web_page_sk AS id , 			sales , 			COALESCE( 				RETURNS, 				0 			) RETURNS , 			( 				profit - COALESCE( 					profit_loss, 					0 				) 			) AS profit 		FROM 			ws 		LEFT JOIN wr ON 			ws.wp_web_page_sk = wr.wp_web_page_sk 	) x GROUP BY 	--ROLLUP ( 		channel, 		id 	--) ORDER BY 	channel , 	id LIMIT 100) "script_1e7d60043245cc650005eac5b0963237"
query_78.sql_1   2020-12-12 19:22:31.809   2020-12-12 19:22:31.809              0               Err     An error has occurred executing the query. Error Message: [SQLITE_ERROR] SQL error or missing database (no such table: catalog_sales) Query: select count(1) from (with ws as  (select d_year AS ws_sold_year, ws_item_sk,   ws_bill_customer_sk ws_customer_sk,   sum(ws_quantity) ws_qty,   sum(ws_wholesale_cost) ws_wc,   sum(ws_sales_price) ws_sp  from web_sales  left join web_returns on wr_order_number=ws_order_number and ws_item_sk=wr_item_sk  join date_dim on ws_sold_date_sk = d_date_sk  where wr_order_number is null  group by d_year, ws_item_sk, ws_bill_customer_sk  ), cs as  (select d_year AS cs_sold_year, cs_item_sk,   cs_bill_customer_sk cs_customer_sk,   sum(cs_quantity) cs_qty,   sum(cs_wholesale_cost) cs_wc,   sum(cs_sales_price) cs_sp  from catalog_sales  left join catalog_returns on cr_order_number=cs_order_number and cs_item_sk=cr_item_sk  join date_dim on cs_sold_date_sk = d_date_sk  where cr_order_number is null  group by d_year, cs_item_sk, cs_bill_customer_sk  ), ss as  (select d_year AS ss_sold_year, ss_item_sk,   ss_customer_sk,   sum(ss_quantity) ss_qty,   sum(ss_wholesale_cost) ss_wc,   sum(ss_sales_price) ss_sp  from store_sales  left join store_returns on sr_ticket_number=ss_ticket_number and ss_item_sk=sr_item_sk  join date_dim on ss_sold_date_sk = d_date_sk  where sr_ticket_number is null  group by d_year, ss_item_sk, ss_customer_sk  ) select ss_sold_year, ss_item_sk, ss_customer_sk, round(ss_qty/(coalesce(ws_qty,0)+coalesce(cs_qty,0)),2) ratio, ss_qty store_qty, ss_wc store_wholesale_cost, ss_sp store_sales_price, coalesce(ws_qty,0)+coalesce(cs_qty,0) other_chan_qty, coalesce(ws_wc,0)+coalesce(cs_wc,0) other_chan_wholesale_cost, coalesce(ws_sp,0)+coalesce(cs_sp,0) other_chan_sales_price from ss left join ws on (ws_sold_year=ss_sold_year and ws_item_sk=ss_item_sk and ws_customer_sk=ss_customer_sk) left join cs on (cs_sold_year=ss_sold_year and cs_item_sk=ss_item_sk and cs_customer_sk=ss_customer_sk) where (coalesce(ws_qty,0)>0 or coalesce(cs_qty, 0)>0) and ss_sold_year=2000 order by  ss_sold_year, ss_item_sk, ss_customer_sk,  ss_qty desc, ss_wc desc, ss_sp desc,  other_chan_qty,  other_chan_wholesale_cost,  other_chan_sales_price,  ratio limit 100) "script_3d0771411604c3b8f912f0bc4365401e"
query_79.sql_1   2020-12-12 19:22:31.809   2020-12-12 19:22:31.839             30         100
query_8.sql_1    2020-12-12 19:22:31.839   2020-12-12 19:22:31.841              2           0
query_80.sql_1   2020-12-12 19:22:31.841   2020-12-12 19:22:31.842              1               Err     An error has occurred executing the query. Error Message: [SQLITE_ERROR] SQL error or missing database (no such table: catalog_sales) Query: select count(1) from (with ssr as (select s_store_id as store_id,      sum(ss_ext_sales_price) as sales,      sum(coalesce(sr_return_amt, 0)) as returns,      sum(ss_net_profit - coalesce(sr_net_loss, 0)) as profit  from store_sales left outer join store_returns on     (ss_item_sk = sr_item_sk and ss_ticket_number = sr_ticket_number),   date_dim,   store,   item,   promotion where ss_sold_date_sk = d_date_sk --    and d_date between cast('1998-08-04' as date) --         and (cast('1998-08-04' as date) + 30 days) 	  and d_date between date('1998-08-04')          and date('1998-08-04', '+30 days')    and ss_store_sk = s_store_sk    and ss_item_sk = i_item_sk    and i_current_price > 50    and ss_promo_sk = p_promo_sk    and p_channel_tv = 'N' group by s_store_id) , csr as (select cp_catalog_page_id as catalog_page_id,      sum(cs_ext_sales_price) as sales,      sum(coalesce(cr_return_amount, 0)) as returns,      sum(cs_net_profit - coalesce(cr_net_loss, 0)) as profit  from catalog_sales left outer join catalog_returns on     (cs_item_sk = cr_item_sk and cs_order_number = cr_order_number),   date_dim,   catalog_page,   item,   promotion where cs_sold_date_sk = d_date_sk --    and d_date between cast('1998-08-04' as date) --         and (cast('1998-08-04' as date) + 30 days) 		and d_date between date('1998-08-04')          and date('1998-08-04', '+30 days')     and cs_catalog_page_sk = cp_catalog_page_sk    and cs_item_sk = i_item_sk    and i_current_price > 50    and cs_promo_sk = p_promo_sk    and p_channel_tv = 'N' group by cp_catalog_page_id) , wsr as (select web_site_id,      sum(ws_ext_sales_price) as sales,      sum(coalesce(wr_return_amt, 0)) as returns,      sum(ws_net_profit - coalesce(wr_net_loss, 0)) as profit  from web_sales left outer join web_returns on     (ws_item_sk = wr_item_sk and ws_order_number = wr_order_number),   date_dim,   web_site,   item,   promotion where ws_sold_date_sk = d_date_sk    --and d_date between cast('1998-08-04' as date)    -- and (cast('1998-08-04' as date) + 30 days)    and d_date between date('1998-08-04')          and date('1998-08-04', '+30 days')     and ws_web_site_sk = web_site_sk    and ws_item_sk = i_item_sk    and i_current_price > 50    and ws_promo_sk = p_promo_sk    and p_channel_tv = 'N' group by web_site_id)  select channel     , id     , sum(sales) as sales     , sum(returns) as returns     , sum(profit) as profit from  (select 'store channel' as channel     , 'store' || store_id as id     , sales     , returns     , profit from  ssr union all select 'catalog channel' as channel     , 'catalog_page' || catalog_page_id as id     , sales     , returns     , profit from csr union all select 'web channel' as channel     , 'web_site' || web_site_id as id     , sales     , returns     , profit from  wsr ) x --group by rollup (channel, id) group by channel, id order by channel     ,id limit 100) "script_c34a3f748fc04c9f19c882634b19293c"
query_81.sql_1   2020-12-12 19:22:31.842   2020-12-12 19:22:31.843              1               Err     An error has occurred executing the query. Error Message: [SQLITE_ERROR] SQL error or missing database (no such table: catalog_returns) Query: select count(1) from (with customer_total_return as (select cr_returning_customer_sk as ctr_customer_sk     ,ca_state as ctr_state,  	sum(cr_return_amt_inc_tax) as ctr_total_return from catalog_returns   ,date_dim   ,customer_address where cr_returned_date_sk = d_date_sk   and d_year =1998  and cr_returning_addr_sk = ca_address_sk  group by cr_returning_customer_sk     ,ca_state )  select c_customer_id,c_salutation,c_first_name,c_last_name,ca_street_number,ca_street_name          ,ca_street_type,ca_suite_number,ca_city,ca_county,ca_state,ca_zip,ca_country,ca_gmt_offset          ,ca_location_type,ctr_total_return from customer_total_return ctr1   ,customer_address   ,customer where ctr1.ctr_total_return > (select avg(ctr_total_return)*1.2 			 from customer_total_return ctr2          	 where ctr1.ctr_state = ctr2.ctr_state)    and ca_address_sk = c_current_addr_sk    and ca_state = 'IL'    and ctr1.ctr_customer_sk = c_customer_sk order by c_customer_id,c_salutation,c_first_name,c_last_name,ca_street_number,ca_street_name          ,ca_street_type,ca_suite_number,ca_city,ca_county,ca_state,ca_zip,ca_country,ca_gmt_offset          ,ca_location_type,ctr_total_return limit 100) "script_b0fb900f4dd4fd353c347449c7c785a9"
query_82.sql_1   2020-12-12 19:22:31.843   2020-12-12 19:22:31.843              0               Err     An error has occurred executing the query. Error Message: [SQLITE_ERROR] SQL error or missing database (no such table: inventory) Query: select count(1) from (select i_item_id    ,i_item_desc    ,i_current_price from item, inventory, date_dim, store_sales where i_current_price between 30 and 30+30 and inv_item_sk = i_item_sk and d_date_sk=inv_date_sk -- and d_date between cast('2002-05-30' as date) and (cast('2002-05-30' as date) + 60 days) and d_date between date('2002-05-30') and date('2002-05-30', '+60 days') and i_manufact_id in (436,128,726,662) and inv_quantity_on_hand between 100 and 500 and ss_item_sk = i_item_sk group by i_item_id,i_item_desc,i_current_price order by i_item_id limit 100) "script_7734142148028bb364077762aa9c7dba"
query_83.sql_1   2020-12-12 19:22:31.843   2020-12-12 19:22:31.844              1               Err     An error has occurred executing the query. Error Message: [SQLITE_ERROR] SQL error or missing database (no such table: web_returns) Query: select count(1) from (with sr_items as (select i_item_id item_id,     sum(sr_return_quantity) sr_item_qty from store_returns,    item,    date_dim where sr_item_sk = i_item_sk and  d_date  in 	(select d_date 	from date_dim 	where d_week_seq in 		(select d_week_seq 		from date_dim 	 where d_date in ('1998-01-02','1998-10-15','1998-11-10'))) and  sr_returned_date_sk  = d_date_sk group by i_item_id), cr_items as (select i_item_id item_id,     sum(cr_return_quantity) cr_item_qty from catalog_returns,    item,    date_dim where cr_item_sk = i_item_sk and  d_date  in 	(select d_date 	from date_dim 	where d_week_seq in 		(select d_week_seq 		from date_dim 	 where d_date in ('1998-01-02','1998-10-15','1998-11-10'))) and  cr_returned_date_sk  = d_date_sk group by i_item_id), wr_items as (select i_item_id item_id,     sum(wr_return_quantity) wr_item_qty from web_returns,    item,    date_dim where wr_item_sk = i_item_sk and  d_date  in 	(select d_date 	from date_dim 	where d_week_seq in 		(select d_week_seq 		from date_dim 		where d_date in ('1998-01-02','1998-10-15','1998-11-10'))) and  wr_returned_date_sk  = d_date_sk group by i_item_id)  select sr_items.item_id    ,sr_item_qty    ,sr_item_qty/(sr_item_qty+cr_item_qty+wr_item_qty)/3.0 * 100 sr_dev    ,cr_item_qty    ,cr_item_qty/(sr_item_qty+cr_item_qty+wr_item_qty)/3.0 * 100 cr_dev    ,wr_item_qty    ,wr_item_qty/(sr_item_qty+cr_item_qty+wr_item_qty)/3.0 * 100 wr_dev    ,(sr_item_qty+cr_item_qty+wr_item_qty)/3.0 average from sr_items   ,cr_items   ,wr_items where sr_items.item_id=cr_items.item_id  and sr_items.item_id=wr_items.item_id  order by sr_items.item_id     ,sr_item_qty limit 100) "script_bebdfb675214fc7108d9a5102d315389"
query_84.sql_1   2020-12-12 19:22:31.844   2020-12-12 19:22:31.855             11           1
query_85.sql_1   2020-12-12 19:22:31.855   2020-12-12 19:22:31.856              1               Err     An error has occurred executing the query. Error Message: [SQLITE_ERROR] SQL error or missing database (no such table: web_sales) Query: select count(1) from (select substr(r_reason_desc,1,20)    ,avg(ws_quantity)    ,avg(wr_refunded_cash)    ,avg(wr_fee) from web_sales, web_returns, web_page, customer_demographics cd1,    customer_demographics cd2, customer_address, date_dim, reason  where ws_web_page_sk = wp_web_page_sk  and ws_item_sk = wr_item_sk  and ws_order_number = wr_order_number  and ws_sold_date_sk = d_date_sk and d_year = 1998  and cd1.cd_demo_sk = wr_refunded_cdemo_sk   and cd2.cd_demo_sk = wr_returning_cdemo_sk  and ca_address_sk = wr_refunded_addr_sk  and r_reason_sk = wr_reason_sk  and  (   (   cd1.cd_marital_status = 'M'   and   cd1.cd_marital_status = cd2.cd_marital_status   and   cd1.cd_education_status = '4 yr Degree'   and    cd1.cd_education_status = cd2.cd_education_status   and   ws_sales_price between 100.00 and 150.00   )  or   (   cd1.cd_marital_status = 'D'   and   cd1.cd_marital_status = cd2.cd_marital_status   and   cd1.cd_education_status = 'Primary'    and   cd1.cd_education_status = cd2.cd_education_status   and   ws_sales_price between 50.00 and 100.00   )  or   (   cd1.cd_marital_status = 'U'   and   cd1.cd_marital_status = cd2.cd_marital_status   and   cd1.cd_education_status = 'Advanced Degree'   and   cd1.cd_education_status = cd2.cd_education_status   and   ws_sales_price between 150.00 and 200.00   )  )  and  (   (   ca_country = 'United States'   and   ca_state in ('KY', 'GA', 'NM')   and ws_net_profit between 100 and 200    )   or   (   ca_country = 'United States'   and   ca_state in ('MT', 'OR', 'IN')   and ws_net_profit between 150 and 300    )   or   (   ca_country = 'United States'   and   ca_state in ('WI', 'MO', 'WV')   and ws_net_profit between 50 and 250    )  ) group by r_reason_desc order by substr(r_reason_desc,1,20)     ,avg(ws_quantity)     ,avg(wr_refunded_cash)     ,avg(wr_fee) limit 100) "script_a8c12d9bba00eedf5ba90c1977050345"
query_86.sql_1   2020-12-12 19:22:31.856   2020-12-12 19:22:31.856              0               Err     An error has occurred executing the query. Error Message: [SQLITE_ERROR] SQL error or missing database (no such table: web_sales) Query: select count(1) from (select    sum(ws_net_paid) as total_sum  ,i_category  ,i_class  --,grouping(i_category)+grouping(i_class) as lochierarchy  ,i_category+i_class as lochierarchy  ,rank() over ( 	--partition by grouping(i_category)+grouping(i_class), 	--case when grouping(i_class) = 0 then i_category end  	partition by i_category+i_class, 	case when i_class = 0 then i_category end 	order by sum(ws_net_paid) desc) as rank_within_parent from   web_sales  ,date_dim    d1  ,item where   d1.d_month_seq between 1212 and 1212+11 and d1.d_date_sk = ws_sold_date_sk and i_item_sk = ws_item_sk --group by rollup(i_category,i_class) group by i_category,i_class order by  lochierarchy desc,  case when lochierarchy = 0 then i_category end,  rank_within_parent limit 100) "script_dcc16e4cc531e01410cd6936f3a33e1c"
query_88.sql_1   2020-12-12 19:22:31.856   2020-12-12 19:22:32.319            463           1
query_89.sql_1   2020-12-12 19:22:32.319   2020-12-12 19:22:32.403             84         100
query_9.sql_1    2020-12-12 19:22:32.403   2020-12-12 19:22:32.404              1           1
query_90.sql_1   2020-12-12 19:22:32.404   2020-12-12 19:22:32.404              0               Err     An error has occurred executing the query. Error Message: [SQLITE_ERROR] SQL error or missing database (no such table: web_sales) Query: select count(1) from (select cast(amc as decimal(15,4))/cast(pmc as decimal(15,4)) am_pm_ratio from ( select count(*) amc    from web_sales, household_demographics , time_dim, web_page    where ws_sold_time_sk = time_dim.t_time_sk     and ws_ship_hdemo_sk = household_demographics.hd_demo_sk     and ws_web_page_sk = web_page.wp_web_page_sk     and time_dim.t_hour between 6 and 6+1     and household_demographics.hd_dep_count = 8     and web_page.wp_char_count between 5000 and 5200) at,    ( select count(*) pmc    from web_sales, household_demographics , time_dim, web_page    where ws_sold_time_sk = time_dim.t_time_sk     and ws_ship_hdemo_sk = household_demographics.hd_demo_sk     and ws_web_page_sk = web_page.wp_web_page_sk     and time_dim.t_hour between 14 and 14+1     and household_demographics.hd_dep_count = 8     and web_page.wp_char_count between 5000 and 5200) pt order by am_pm_ratio limit 100) "script_a54a32f5f8658666ef3992a28cf50170"
query_91.sql_1   2020-12-12 19:22:32.404   2020-12-12 19:22:32.404              0               Err     An error has occurred executing the query. Error Message: [SQLITE_ERROR] SQL error or missing database (no such table: call_center) Query: select count(1) from (select      cc_call_center_id Call_Center,     cc_name Call_Center_Name,     cc_manager Manager,     sum(cr_net_loss) Returns_Loss from     call_center,     catalog_returns,     date_dim,     customer,     customer_address,     customer_demographics,     household_demographics where     cr_call_center_sk    = cc_call_center_sk and   cr_returned_date_sk   = d_date_sk and   cr_returning_customer_sk= c_customer_sk and   cd_demo_sk       = c_current_cdemo_sk and   hd_demo_sk       = c_current_hdemo_sk and   ca_address_sk      = c_current_addr_sk and   d_year         = 1999 and   d_moy          = 11 and   ( (cd_marital_status    = 'M' and cd_education_status   = 'Unknown')     or(cd_marital_status    = 'W' and cd_education_status   = 'Advanced Degree')) and   hd_buy_potential like '0-500%' and   ca_gmt_offset      = -7 group by cc_call_center_id,cc_name,cc_manager,cd_marital_status,cd_education_status order by sum(cr_net_loss) desc) "script_2b9bd020c87203b51f63805d9f9bbd81"
query_92.sql_1   2020-12-12 19:22:32.404   2020-12-12 19:22:32.405              1               Err     An error has occurred executing the query. Error Message: [SQLITE_ERROR] SQL error or missing database (no such table: web_sales) Query: select count(1) from (select   sum(ws_ext_discount_amt) as "Excess Discount Amount" from   web_sales   ,item   ,date_dim where i_manufact_id = 269 and i_item_sk = ws_item_sk --and d_date between '1998-03-18' and --    (cast('1998-03-18' as date) + 90 days) and d_date between date('1998-03-18') and     date('1998-03-18','+90 days') and d_date_sk = ws_sold_date_sk and ws_ext_discount_amt    > (      SELECT       1.3 * avg(ws_ext_discount_amt)      FROM       web_sales       ,date_dim     WHERE        ws_item_sk = i_item_sk --     and d_date between '1998-03-18' and --               (cast('1998-03-18' as date) + 90 days) 	and d_date between date('1998-03-18') and     date('1998-03-18','+90 days')      and d_date_sk = ws_sold_date_sk    ) order by sum(ws_ext_discount_amt) limit 100) "script_36175fd8095dbb9fa9555d0f42d010de"
query_93.sql_1   2020-12-12 19:22:32.405   2020-12-12 19:22:32.407              2           0
query_94.sql_1   2020-12-12 19:22:32.407   2020-12-12 19:22:32.407              0               Err     An error has occurred executing the query. Error Message: [SQLITE_ERROR] SQL error or missing database (no such table: web_sales) Query: select count(1) from (select   count(distinct ws_order_number) as "order count"  ,sum(ws_ext_ship_cost) as "total shipping cost"  ,sum(ws_net_profit) as "total net profit" from  web_sales ws1  ,date_dim  ,customer_address  ,web_site where --  d_date between '1999-5-01' and --      (cast('1999-5-01' as date) + 60 days)   d_date between date('1999-5-01') and       date('1999-5-01', '+60 days') and ws1.ws_ship_date_sk = d_date_sk and ws1.ws_ship_addr_sk = ca_address_sk and ca_state = 'TX' and ws1.ws_web_site_sk = web_site_sk and web_company_name = 'pri' and exists (select *       from web_sales ws2       where ws1.ws_order_number = ws2.ws_order_number        and ws1.ws_warehouse_sk <> ws2.ws_warehouse_sk) and not exists(select *        from web_returns wr1        where ws1.ws_order_number = wr1.wr_order_number) order by count(distinct ws_order_number) limit 100) "script_4476f90c215d35fe5408890cdb226486"
query_95.sql_1   2020-12-12 19:22:32.407   2020-12-12 19:22:32.408              1               Err     An error has occurred executing the query. Error Message: [SQLITE_ERROR] SQL error or missing database (no such table: web_sales) Query: select count(1) from (with ws_wh as (select ws1.ws_order_number,ws1.ws_warehouse_sk wh1,ws2.ws_warehouse_sk wh2 from web_sales ws1,web_sales ws2 where ws1.ws_order_number = ws2.ws_order_number  and ws1.ws_warehouse_sk <> ws2.ws_warehouse_sk) select   count(distinct ws_order_number) as "order count"  ,sum(ws_ext_ship_cost) as "total shipping cost"  ,sum(ws_net_profit) as "total net profit" from  web_sales ws1  ,date_dim  ,customer_address  ,web_site where --  d_date between '1999-5-01' and --      (cast('1999-5-01' as date) + 60 days)   d_date between date('1999-5-01') and       date('1999-5-01', '+60 days') and ws1.ws_ship_date_sk = d_date_sk and ws1.ws_ship_addr_sk = ca_address_sk and ca_state = 'TX' and ws1.ws_web_site_sk = web_site_sk and web_company_name = 'pri' and ws1.ws_order_number in (select ws_order_number               from ws_wh) and ws1.ws_order_number in (select wr_order_number               from web_returns,ws_wh               where wr_order_number = ws_wh.ws_order_number) order by count(distinct ws_order_number) limit 100) "script_dee997331123086cf7f92cf35c6d3d88"
query_96.sql_1   2020-12-12 19:22:32.408   2020-12-12 19:22:32.456             48           1
query_98.sql_1   2020-12-12 19:22:32.456   2020-12-12 19:22:32.526             70         237
query_99.sql_1   2020-12-12 19:22:32.526   2020-12-12 19:22:32.527              1               Err     An error has occurred executing the query. Error Message: [SQLITE_ERROR] SQL error or missing database (no such table: catalog_sales) Query: select count(1) from (select   substr(w_warehouse_name,1,20)  ,sm_type  ,cc_name  ,sum(case when (cs_ship_date_sk - cs_sold_date_sk <= 30 ) then 1 else 0 end) as "30 days"  ,sum(case when (cs_ship_date_sk - cs_sold_date_sk > 30) and          (cs_ship_date_sk - cs_sold_date_sk <= 60) then 1 else 0 end ) as "31-60 days"  ,sum(case when (cs_ship_date_sk - cs_sold_date_sk > 60) and          (cs_ship_date_sk - cs_sold_date_sk <= 90) then 1 else 0 end) as "61-90 days"  ,sum(case when (cs_ship_date_sk - cs_sold_date_sk > 90) and         (cs_ship_date_sk - cs_sold_date_sk <= 120) then 1 else 0 end) as "91-120 days"  ,sum(case when (cs_ship_date_sk - cs_sold_date_sk > 120) then 1 else 0 end) as ">120 days" from  catalog_sales  ,warehouse  ,ship_mode  ,call_center  ,date_dim where   d_month_seq between 1212 and 1212 + 11 and cs_ship_date_sk  = d_date_sk and cs_warehouse_sk  = w_warehouse_sk and cs_ship_mode_sk  = sm_ship_mode_sk and cs_call_center_sk = cc_call_center_sk group by  substr(w_warehouse_name,1,20)  ,sm_type  ,cc_name order by substr(w_warehouse_name,1,20)     ,sm_type     ,cc_name limit 100) "script_ba365ec065481c854bf7c4f4c46da852"

Task Runner