PK r2<UNW_Storage/Joins/PK r2<UNW_Storage/Tables/PK r2<ę域UNW_Storage/Contexts/Contexts›All! $9:;<=>?@ABCDHJKLPK r2<UNW_Storage/Contexts/PK r2<ßD!!UNW_Storage/Dot_Tables/Dot_TablesPK r2<UNW_Storage/Dot_Tables/PK r2<UNW_Storage/Connection/PK r2<UNW_Storage/Parameters/PK r2>1UNW_Storage/Crystal_References/Crystal_References10JJqKgSWtB7yN8ASLJvmMz7itGnTCJkAQgExAPK r2<UNW_Storage/Crystal_References/PK r2<ßD!9UNW_Storage/ Upward_AggregateAware/ Upward_AggregateAwarePK r2<#UNW_Storage/ Upward_AggregateAware/PK r2<)UNW_Storage/Dynamic_Objects_Descriptions/PK r2<ßD!EUNW_Storage/Dynamic_Classes_Descriptions/Dynamic_Classes_DescriptionsPK r2<)UNW_Storage/Dynamic_Classes_Descriptions/PK r2<ßD!KUNW_Storage/Dynamic_Properties_Descriptions/Dynamic_Properties_DescriptionsPK r2<,UNW_Storage/Dynamic_Properties_Descriptions/PK r2< UNW_Storage/PK r2<˙ŮAResourceHeader|/B-Descriptor;PK r2zJJ(ResourceHeader|/BusinessObjects Reserved T-Descriptor B-Descriptor DescriptorPK r2<ResourceHeader|/PK r2<wN‘((Audit; PK r2<ßD!XML-LOV;PK r2<›ŐUpward;PK `I;’ JLPlatformWindowsPK r2< UNICODE ONPK r2<ßD! Downward;PK r2?@ABCDHJKLPK r2Mode1? Emp_Rollup@ Country_SalesB Derived_TableCBinningPK r2<ßD!Columns References;PK r2 3=„3 customer_id customer_id_? !3=„3 promotion_id promotion_idW@ "3=„3store_idstore_id[A %3=„3 sales_date sales_dateYB &3=„3 basket_id basket_id]C4=„4 customer_id customer_id[D5=„5 product_id product_id]H &==„= customer_id customer_idaJ5554DE=„D setversion_idE setversion_idKKAAA2DD=4$D subject_idTL'''E=„Eid customer_idPK r2<0Ńgó::UNW_Storage/Tables/Tables¤pĐdbo.Current_Facts " product_id# customer_id$ promotion_id store_id# store_sales" store_cost" unit_sales" sales_date! basket_id$ store_margint˙° @ dbo.customer# customer_id# account_numlnamefnamemi address1 address2 address3 address4city&state_province# postal_codecountry*customer_region_idphone1phone2! birthdate&marital_status% yearly_incomegender&total_children,num_children_at_home! education)date_accnt_opened# member_card" occupation" houseowner&num_cars_owned*(T°0 dbo.product(product_class_id" product_id" brand_name$ product_nameSKUSRP$ gross_weight" net_weight*recyclable_packagelow_fat&units_per_case(cases_per_pallet# shelf_width$ shelf_height# shelf_depth Ŕ0Pdbo.product_class(product_class_id+product_subcategory(product_category*product_department&product_familyo@°°@  dbo.promotion$ promotion_id-promotion_district_id&promotion_name" media_typecost" start_date end_dateIž°P@Đ dbo.store store_id" store_type! region_id" store_name$ store_number,store_street_address" store_city# store_state)store_postal_code% store_country% store_manager# store_phone! store_fax)first_opened_date)last_remodel_date" lease_sqft" store_sqft$ grocery_sqft# frozen_sqft! meat_sqft" coffee_bar# video_store! salad_bar% prepared_foodfloristŃ °00€ dbo.set_set(set_id" subject_idname" first_dateuser_id" project_idrecords last_modstatus" autoupdate comments# expiry_date! expiry_id% targetuser_id% setversion_id$ is_versioned is_built# dtime_built&partbld_actseq'refresh_freq_id# calendar_id&base_period_id# last_ref_id&date_refreshed$ hist_periods&hist_directive# is_external# is_terminal# is_del_mark'is_lock_if_done% no_of_actions(is_allow_tlogicd)no_of_cycles_done&own_table_name'is_test_autoinc&is_lmt_autoinc&is_points_sens! is_frozen'curr_det_tbl_id'reqd_det_tbl_idĺ ŕ€Pdbo.set_set_detail% setversion_ididpointssdateedateĎŻ°Ŕ pdbo.Date_Ranges" Date_Range" Begin_Date End_DateŹ&ŔŔ@€ Rolling_Weeks" Begin_Date(Week_Ending_Dateselect distinct dateadd(wk,-@Prompt('No. of Weeks','N',,mono,free),(dbo.Current_Facts.sales_date - DATEPART(dw, dbo.Current_Facts.sales_date))+7) as Begin_Date, (dbo.Current_Facts.sales_date - DATEPART(dw, dbo.Current_Facts.sales_date))+7 as Week_Ending_Date from Current_Facts‘)PWeek_Ending_Facts(Week_Ending_DateSalesűselect (dbo.Current_Facts.sales_date - DATEPART(dw, dbo.Current_Facts.sales_date))+7 as Week_Ending_Date, sum(Current_Facts.store_sales) as Sales from Current_Facts group by (dbo.Current_Facts.sales_date - DATEPART(dw, dbo.Current_Facts.sales_date))+7+Ŕ€ Monthly_Facts(Week_Ending_DateSalesűselect (dbo.Current_Facts.sales_date - DATEPART(dw, dbo.Current_Facts.sales_date))+7 as Week_Ending_Date, sum(Current_Facts.store_sales) as Sales from Current_Facts group by (dbo.Current_Facts.sales_date - DATEPART(dw, dbo.Current_Facts.sales_date))+7ł,Ŕp€Top_5_Products" Product_IDSales&SELECT Top 5 Current_Facts.product_id as Product_ID, sum(Current_Facts.store_sales) as Sales FROM Current_Facts where Current_Facts.store_id = (select store.store_id from store where store.store_manager = @Variable('BOUSER') ) GROUP BY Current_Facts.product_id ORDER BY 2 DESCĂ.Ŕ€€Interval_Banding# Lower_Value# Upper_Value-select @Prompt('1st Bin','N',,mono,free) as Lower_Value, @Prompt('2nd Bin','N',,mono,free) as Upper_Value from syscolumns union select @Prompt('2nd Bin','N',,mono,free)+.01 as Lower_Value, @Prompt('3rd Bin','N',,mono,free) as Upper_Value from syscolumns union select @Prompt('3rd Bin','N',,mono,free)+.01 as Lower_Value, @Prompt('4th Bin','N',,mono,free) as Upper_Value from syscolumns union select @Prompt('4th Bin','N',,mono,free)+.01 as Lower_Value, @Prompt('5th Bin','N',,mono,free) as Upper_Value from syscolumns union select @Prompt('5th Bin','N',,mono,free)+.01 as Lower_Value, @Prompt('6th Bin','N',,mono,free) as Upper_Value from syscolumns union select @Prompt('6th Bin','N',,mono,free)+.01 as Lower_Value, @Prompt('7th Bin','N',,mono,free) as Upper_Value from syscolumns union select @Prompt('7th Bin','N',,mono,free)+.01 as Lower_Value, @Prompt('8th Bin','N',,mono,free) as Upper_Value from syscolumns union select @Prompt('8th Bin','N',,mono,free)+.01 as Lower_Value, @Prompt('9th Bin','N',,mono,free) as Upper_Value from syscolumns 6/đ €Basket_Summary$! basket_id*Number_of_Products# store_sales" store_cost$ store_margin" sales_date store_id# customer_id'Number_of_Items" Margin_Pct$ Promotion_ID+Avg_Margin_Per_Item*Avg_Price_per_Item+Alcoholic_Beverages# Baked_Goods$ Baking_Goods! Beverages'Breakfast_Foods$ Canned_Foods'Canned_ProductsCarosel CheckoutDairyDeliEggs$ Frozen_Foods*Health_and_Hygiene! HouseholdMeat&Packaged_Foods# PeriodicalsProduceSeafood# Snack_FoodsSnacks% Starchy_Foods1 P0 Ten_Random_Customers# Customer_IDŸselect floor((10281*rand())) as Customer_ID from syscolumns union select floor((10281*rand())) as Customer_ID from syscolumns union select floor((10281*rand())) as Customer_ID from syscolumns union select floor((10281*rand())) as Customer_ID from syscolumns union select floor((10281*rand())) as Customer_ID from syscolumns union select floor((10281*rand())) as Customer_ID from syscolumns union select floor((10281*rand())) as Customer_ID from syscolumns union select floor((10281*rand())) as Customer_ID from syscolumns union select floor((10281*rand())) as Customer_ID from syscolumns union select floor((10281*rand())) as Customer_ID from syscolumnsó3€°ŕMost_Recent_2_Days" product_id# customer_id$ promotion_id store_id" sales_date! basket_id'Last_Days_Sales.Penultimate_Days_Salest€select Current_Facts.product_id,Current_Facts.customer_id,Current_Facts.promotion_id,Current_Facts.store_id,Current_Facts.sales_date,Current_Facts.basket_id, case when Current_Facts.sales_date = (select max(dbo.Current_Facts.sales_date) from dbo.Current_Facts) then Current_Facts.store_sales else 0 end as Last_Days_Sales, case when dbo.Current_Facts.sales_date = (select min(Last_Two_Dates.Last_Two_Dates) from (select distinct top 2 Current_Facts.sales_date as Last_Two_Dates from Current_Facts order by Current_Facts.sales_date desc) Last_Two_Dates) then Current_Facts.store_sales else 0 end as Penultimate_Days_Sales from Current_Factsę4° ŔTop_N_Customers# customer_id# Store_SalesUselect top @Prompt('How Many Customers','N',,mono,free) Current_Facts.customer_id as customer_id, sum(Current_Facts.store_sales) as Store_Sales from Current_Facts where datediff(d,dbo.Current_Facts.sales_date,getdate())<=@Prompt('How Many Days','N',,mono,free) group by Current_Facts.customer_id order by sum(Current_Facts.store_sales) desc~5°đ °Top_N_Prod_Cust" product_id# Store_Salesęselect top @Prompt('How Many Products','N',,mono,free) Current_Facts.product_id as product_id, sum(Current_Facts.store_sales) as Store_Sales from Current_Facts where Current_Facts.customer_id in (select distinct customer_id from (select top @Prompt('How Many Customers','N',,mono,free) Current_Facts.customer_id, sum(Current_Facts.store_sales) as Store_Sales from Current_Facts where datediff(d,dbo.Current_Facts.sales_date,getdate())<=@Prompt('How Many Days','N',,mono,free) group by Current_Facts.customer_id order by sum(Current_Facts.store_sales) desc) Top_N_Sales) and datediff(d,dbo.Current_Facts.sales_date,getdate())<=@Prompt('How Many Days','N',,mono,free) group by Current_Facts.product_id order by sum(Current_Facts.store_sales) desch=ŕp Avg_Days# customer_id Avg_DaysÝselect Current_Facts.customer_id, cast((datediff(d,min(Current_Facts.sales_date),max(Current_Facts.sales_date))) as float)/(count(*)-1) as Avg_Days from Current_Facts group by Current_Facts.customer_id having count(*) > 1 AŔ`€ User_Prompt! User_NameMessage•select 'Administrator' as User_Name, 'What Date' as Message from syscolumns union select 'Jose' as User_Name, 'Que Dia?' as Message from syscolumnsB`ĐĐ€Prompted_Binning# Lower_Value# Upper_Value Bin_NameJselect 0 as Lower_Value, @Prompt('1st Bin','N',,mono,free) as Upper_Value, 'Below '+cast(@Variable('1st Bin') as char(4)) as Bin_Name from syscolumns union select @Prompt('1st Bin','N',,mono,free)+.01 as Lower_Value, @Prompt('2nd Bin','N',,mono,free) as Upper_Value, 'Between '+cast(@Variable('1st Bin') as char(4))+' and '+cast(@Variable('2nd Bin') as char(1)) as Bin_Name from syscolumns union select @Prompt('2nd Bin','N',,mono,free)+.01 as Lower_Value, 99999 as Upper_Value, 'Greater than '+cast(@Variable('2nd Bin') as char(4)) as Bin_Name from syscolumns D €Đ€ customer_set K €customer_set_detail ĎC€`@ product_set J `ŕproduct_set_detail ĎB    basket_set I°` ŕbasket_set_detail ĎFD€đŕpredictive_set ME ŕ ppredictive_set_detail ĎPK r2<ůÎÚHËË!UNW_Storage/Connection/ConnectionnGeneric ODBC datasource yGyAz[>y75yGkycy]3z]xOybyoz?z6zM>x5yBzCzB?[xEyDzHhx9z]xQzRzix>hygzdmzZzj\x9y:+zC1z=ysz1:yKyQzDz7;ySzOyqxIxzJxRz7YzQzHxNy4VyD^qx:Fy[x:lyHKyQ(yAyCy=yE3gxU]y>yYxPy3zV9YyqxSyGx9z:ynNzmx=zPyI:zgb[z6x3y5xGx=z\z:2x1xTzmxLz3yQy;ytySRxIxWZyYyUy1\yJz>zpyWgyIkyfy5yZ?fyhy^@zd^zay4xEAvzeyXyysz=zGyUxWyhyqytyKz=zN-vy>zyPxQByMzIyrxQyMyoB]yA8yTzTyByIzZx3yqez_z@=zOyEzK`yVxFxJyRy@y]hznz`z>y6yj]zYzIx1zmzazFyex6z\z@z`z_x=iyUyQhxEy2x6yB(x;xEyCyW[ybxGyYyJxNMxSzlypzny7y4KNxCzlz:x>z9yUyeryCyhz^xNyJx5bx7y]xCzD]OxLx5zaydyMyRy1zdyzJxRz7YzQzHxNy4VixMx0ybz=y:yyYyKx0+y`x6zqyOyuzgyixLx9y`cyjzWy6ykzg^zbzaymy5zUyezHx;dy;p^xSyIz?z9y4zqyK(yiy:yGy]yvzDy^z>zEzp9yqyOzz@mzPyP)yOzDytxUy5xVtyoxUx4yKzK`yVxFxJyRy@y]hznz`z>y6yj]zYzIx1zmzazFyex6z\zGjymcjyGyQzjzpUz7yMzM,yhyOyW[ybxGyYyJxNM@t@x:gyPgy3yHx0z>,xOy;[vz^zfzBz;ygy`xRz>czfyoxBwydzQ1zgkxOy_h8y4x4zK`yVxFxJyRy@y]hznz`z>y6yj]zYzIx1zmzazFyex6z\y:AcczKyBry2WynKyPzFyky5z3xDux:z5yeyGpy92z7z?yBlyEz0xW/z>ysz=zGyUxWyhzysz=zGyUxWyhy3x:o2zN>x6zCxUyRz0yTy_y6z]ySdy;p^xSyIz?z9y4zqyK(yiy:yGy]yvzDy^z>zEzp9yqxJxQzUzdz[yKz4z@zU,zpyWgyIkyfy5yZ?fyhy^@zd^zay4xEA5yUyurz;y^*y>X0;z`ygySy1zyfyN/ByMzIyrxQyMyoBy_zCz\xKz:y9yOlxIyDz1zQ;x>x:znnz\DyPzLy3ybyN@zhyjzOyPxIykVx8sax?y@+Qz=yiz6y`W8yGzRzpxJSz3xysz=zGyUxWyhzyByuzVzBymyMzoNyPx3xFyjy@z5yty2Dz8xExRxS9yqzkyDxFz9yFy5zEx@Jz5z_zN1xTz5y8ODBC yGyAz[>y75yGkycy]3z]xOybyoz?z6zM>x5yBzCzB?[xEyDzHhx9z]xQzRzix>hygzdmzZzj\x9y:+zC1z=ysz1:yKyQzDz7;ySzOyqxIxzJxRz7YzQzHxNy4VyD^qx:Fy[x:lyHKyQ(yAyCy=yE3gxU]y>yYxPy3zV9YyqxSyGx9z:ynNzmx=zPyI:zgb[z6x3y5xGx=z\z:2x1xTzmxLz3yQy;ytySRxIxWZyYyUy1\yJz>zpyWgyIkyfy5yZ?fyhy^@zd^zay4xEAvzeyXyysz=zGyUxWyhyqytyKz=zN-vy>zyPxQByMzIyrxQyMyoB]yA8yTzTyByIzZx3yqez_z@=zOyEzK`yVxFxJyRy@y]hznz`z>y6yj]zYzIx1zmzazFyex6z\z@z`z_x=iyUyQhxEy2x6yB(x;xEyCyW[ybxGyYyJxNMxSzlypzny7y4KNxCzlz:x>z9yUyeryCyhz^xNyJx5bx7y]xCzD]OxLx5zaydyMyRy1zdyzJxRz7YzQzHxNy4VixMx0ybz=y:yyYyKx0+y`x6zqyOyuzgyixLx9y`cyjzWy6ykzg^zbzaymy5zUyezHx;dy;p^xSyIz?z9y4zqyK(yiy:yGy]yvzDy^z>zEzp9yqyOzz@mzPyP)yOzDytxUy5xVtyoxUx4yKzK`yVxFxJyRy@y]hznz`z>y6yj]zYzIx1zmzazFyex6z\zGjymcjyGyQzjzpUz7yMzM,yhyOyW[ybxGyYyJxNM@t@x:gyPgy3yHx0z>,xOy;[vz^zfzBz;ygy`xRz>czfyoxBwydzQ1zgkxOy_h8y4x4zK`yVxFxJyRy@y]hznz`z>y6yj]zYzIx1zmzazFyex6z\y:AcczKyBry2WynKyPzFyky5z3xDux:z5yeyGpy92z7z?yBlyEz0xW/z>ysz=zGyUxWyhzysz=zGyUxWyhy3x:o2zN>x6zCxUyRz0yTy_y6z]ySdy;p^xSyIz?z9y4zqyK(yiy:yGy]yvzDy^z>zEzp9yqxJxQzUzdz[yKz4z@zU,zpyWgyIkyfy5yZ?fyhy^@zd^zay4xEA5yUyurz;y^*y>X0;z`ygySy1zyfyN/ByMzIyrxQyMyoBy_zCz\xKz:y9yOlxIyDz1zQ;x>x:znnz\DyPzLy3ybyN@zhyjzOyPxIykVx8sax?y@+Qz=yiz6y`W8yGzRzpxJSz3xysz=zGyUxWyhzyByuzVzBymyMzoNyPx3xFyjy@z5ytz0UzJxEd5]zUym/?^jyMziyVzRyEzRszgxNByEdummyyexLx6y6x:gry5yVylDxKygyWyiz6y`W8yGzRzpdQzbyIzOyIy1\zKygwx8cxPzMz]xSzlyE(`xRy4zfz9yYz`y[axT]z`x8yqz;yXsy:yKyRhz6xL1yPyZyGzpzW_ey:myXyYykxV>xRxIySzpz9xPu,zTyY-y9cpzV9YyqxSyGx9z:y@Jznyez= case when @Prompt('What Measure?','A',{'Sales','Cost','Margin','Units'},mono,constrained) = 'Sales' then 1.store_sales when @Prompt('What Measure?','A',{'Sales','Cost','Margin','Units'},mono,constrained) = 'Cost' then 1.store_cost when @Prompt('What Measure?','A',{'Sales','Cost','Margin','Units'},mono,constrained) = 'Margin' then 1.store_margin else 1.unit_sales endš=*Averages ˆ”şAverage Sales per CustomerAcast(sum(1.store_sales)/count(distinct 1.customer_id) as float)0objec05bŚ_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&4~&0~&0~&-1~&-1~&-1~&-1~&L[$]T[#]T[gs]T[#]T[#]T[0]T[ds]T[0]T[0]~&~&~&~&~&~&~&NF_~&SIMSTY_~&„ăAverage Sales per Basket?cast(sum(1.store_sales)/count(distinct 1.basket_id) as float)0avera06hŚ_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&4~&0~&0~&-1~&-1~&-1~&-1~&L[$]T[#]T[gs]T[#]T[#]T[0]T[ds]T[0]T[0]~&~&~&~&~&~&~&NF_~&SIMSTY_~&x„ŤAverage Price per Unit5cast(sum(1.store_sales)/sum(1.unit_sales) as float)0objec04vŚ_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&4~&0~&0~&-1~&-1~&-1~&-1~&L[$]T[#]T[gs]T[#]T[#]T[0]T[ds]T[0]T[0]~&~&~&~&~&~&~&NF_~&SIMSTY_~&Š–âAverage Margin per CustomerBcast(sum(1.store_margin)/count(distinct 1.customer_id) as float)0avera06gŚ_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&4~&0~&0~&-1~&-1~&-1~&-1~&L[$]T[#]T[gs]T[#]T[#]T[0]T[ds]T[0]T[0]~&~&~&~&~&~&~&NF_~&SIMSTY_~&†’ĆAverage Margin per Basket@cast(sum(1.store_margin)/count(distinct 1.basket_id) as float)0objec05nŚ_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&4~&0~&0~&-1~&-1~&-1~&-1~&L[$]T[#]T[gs]T[#]T[#]T[0]T[ds]T[0]T[0]~&~&~&~&~&~&~&NF_~&SIMSTY_~&kwAverage Margin per Item'sum(1.store_margin)/sum(1.unit_sales)0avera0moŚ_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&4~&0~&0~&-1~&-1~&-1~&-1~&L[$]T[#]T[gs]T[#]T[#]T[0]T[ds]T[0]T[0]~&~&~&~&~&~&~&NF_~&SIMSTY_~&\sAverage Margin Pct(sum(1.store_margin)/sum(1.store_sales)0avera0mm›_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&7~&0~&0~&-1~&-1~&-1~&-1~&T[0]T[ds]T[0]T[0]L[ %]T[pc]~&~&~&~&~&~&~&NF_~&SIMSTY_~&:QGoal Margin Pct avg(.600)0objec0py›_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&7~&0~&0~&-1~&-1~&-1~&-1~&T[0]T[ds]T[0]T[0]L[ %]T[pc]~&~&~&~&~&~&~&NF_~&SIMSTY_~&ZqŽPrompted Goal Pct'avg(@Prompt('Goal Pct','N',,mono,free))0goal_0q0›_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&7~&0~&0~&-1~&-1~&-1~&-1~&T[0]T[ds]T[0]T[0]L[ %]T[pc]~&~&~&~&~&~&~&NF_~&SIMSTY_~&§ˇš"Average Number of Items per Basket\cast(cast(sum(1.unit_sales) as float)/cast(count(distinct 1.basket_id) as float) as float)0objec05a˘_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&3~&0~&0~&-1~&-1~&-1~&-1~&T[#]T[gs]T[#]T[#]T[0]T[ds]T[0]T[0]~&~&~&~&~&~&~&NF_~&SIMSTY_~&×çAverage Number of Visits–case when count(distinct 1.customer_id) = 0 then 0 else cast(count(distinct 1.basket_id) as float)/cast(count(distinct 1.customer_id) as float) end0avera0mn˘_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&3~&0~&0~&-1~&-1~&-1~&-1~&T[#]T[gs]T[#]T[#]T[0]T[ds]T[0]T[0]~&~&~&~&~&~&~&NF_~&SIMSTY_~&6F'Avg Number of Baskets per Store per Dayćcase when (count(distinct 1.store_id)=0 or count(distinct 1.sales_date) = 0) then 0 else (cast(count(distinct 1.basket_id) as float)/cast(count(distinct 1.store_id) as float)/cast(count(distinct 1.sales_date) as float))*6 end0avera0mp˘_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&3~&0~&0~&-1~&-1~&-1~&-1~&T[#]T[gs]T[#]T[#]T[0]T[ds]T[0]T[0]~&~&~&~&~&~&~&NF_~&SIMSTY_~&ÄvAvg Days$Average Days between Customer Visitsavg(61.Avg_Days)=0avg_d0pm­;+CountsMjšNumber of Customerscount(distinct 2.customer_id)0objec04e•_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&3~&0~&0~&-1~&-1~&-1~&-1~&T[#]T[gs]T[#]T[#]T[0]~&~&~&~&~&~&~&NF_~&SIMSTY_~&™śnNumber of Married CustomersbCAST(count(distinct case when 2.marital_status = 'M' then 2.customer_id else NULL end) AS FLOAT)0no__o0p3•_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&3~&0~&0~&-1~&-1~&-1~&-1~&T[#]T[gs]T[#]T[#]T[0]~&~&~&~&~&~&~&NF_~&SIMSTY_~&KhÍNumber of Productscount(distinct 3.product_id)0produ05u•_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&3~&0~&0~&-1~&-1~&-1~&-1~&T[#]T[gs]T[#]T[#]T[0]~&~&~&~&~&~&~&NF_~&SIMSTY_~&GdćNumber of Storescount(distinct 6.store_id)0no__o06k•_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&3~&0~&0~&-1~&-1~&-1~&-1~&T[#]T[gs]T[#]T[#]T[0]~&~&~&~&~&~&~&NF_~&SIMSTY_~&´f$Number of Brandscount(distinct 3.brand_name)0objec0my8 K>Counts from Fact Tablec•Number of Customers Sold To-cast(COUNT(DISTINCT 1.customer_id) as float)0custo0q7”_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&3~&0~&0~&-1~&-1~&-1~&-1~&T[#]T[gs]T[#]T[#]T[0]~&~&~&~&~&~&~&NF_~&SIMSTY_~&]z›Number of Baskets Sold+cast(COUNT(DISTINCT 1.basket_id) as float)0baske04f•_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&3~&0~&0~&-1~&-1~&-1~&-1~&T[#]T[gs]T[#]T[#]T[0]~&~&~&~&~&~&~&NF_~&SIMSTY_~&c”Number of Products Purchased,cast(COUNT(DISTINCT 1.product_id) as float)0produ0q6”_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&3~&0~&0~&-1~&-1~&-1~&-1~&T[#]T[gs]T[#]T[#]T[0]~&~&~&~&~&~&~&NF_~&SIMSTY_~&`~–Number of Stores Shopped In*cast(COUNT(DISTINCT 1.store_id) as float)0store0q8”_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&3~&0~&0~&-1~&-1~&-1~&-1~&T[#]T[gs]T[#]T[#]T[0]~&~&~&~&~&~&~&NF_~&SIMSTY_~&]{—Number of Promotions.cast(COUNT(DISTINCT 1.promotion_id) as float)0promo0q9”_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&3~&0~&0~&-1~&-1~&-1~&-1~&T[#]T[gs]T[#]T[#]T[0]~&~&~&~&~&~&~&NF_~&SIMSTY_~&ÁĽKTime Specific Measuresˆ;YearlyŞß YTD Salessum(case when datepart(yyyy,1.sales_date)=datepart(yyyy,getdate()) and 1.sales_date<= getdate() then 1.store_sales else 0 end)0sales04j™_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&4~&0~&0~&-1~&-1~&-1~&-1~&L[$]T[#]T[gs]T[#]T[#]T[0]~&~&~&~&~&~&~&NF_~&SIMSTY_~&ŇëĄPrevious Year TD Salesœsum(case when datepart(yyyy,1.sales_date)=datepart(yyyy,getdate())-1 and datepart(dy,1.sales_date)<=datepart(dy,getdate()) then 1.store_sales else 0 end)0ytd_s04l™_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&4~&0~&0~&-1~&-1~&-1~&-1~&L[$]T[#]T[gs]T[#]T[#]T[0]~&~&~&~&~&~&~&NF_~&SIMSTY_~&]vŁYTD Sales less Prev Yr TD Salessum(case when datepart(yyyy,1.sales_date)=datepart(yyyy,getdate()) and 1.sales_date<= getdate() then 1.store_sales else 0 end)-sum(case when datepart(yyyy,1.sales_date)=datepart(yyyy,getdate())-1 and datepart(dy,1.sales_date)<=datepart(dy,getdate()) then 1.store_sales else 0 end)0ytd_s04n™_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&4~&0~&0~&-1~&-1~&-1~&-1~&L[$]T[#]T[gs]T[#]T[#]T[0]~&~&~&~&~&~&~&NF_~&SIMSTY_~&4YTD Sales vs Prev Yr TD Sales %Ücase when sum(case when datepart(yyyy,1.sales_date)=datepart(yyyy,getdate())-1 and datepart(dy,1.sales_date)<=datepart(dy,getdate()) then 1.store_sales else 0 end)=0 then 0 else (sum(case when datepart(yyyy,1.sales_date)=datepart(yyyy,getdate()) and 1.sales_date<= getdate() then 1.store_sales else 0 end)/sum(case when datepart(yyyy,1.sales_date)=datepart(yyyy,getdate())-1 and datepart(dy,1.sales_date)<=datepart(dy,getdate()) then 1.store_sales else 0 end))-1 end0ytd_s0mr›_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&7~&0~&0~&-1~&-1~&-1~&-1~&T[0]T[ds]T[0]T[0]L[ %]T[pc]~&~&~&~&~&~&~&NF_~&SIMSTY_~&˜ąśPrevious Year Salesesum(case when datepart(yyyy,1.sales_date)=datepart(yyyy,getdate())-1 then 1.store_sales else 0 end)0ytd_s057™_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&4~&0~&0~&-1~&-1~&-1~&-1~&L[$]T[#]T[gs]T[#]T[#]T[0]~&~&~&~&~&~&~&NF_~&SIMSTY_~&ąČ/YTD No. Customers vs Prev Yr TD No. Customers %`(cast(count (distinct case when datepart(yyyy,1.sales_date)=datepart(yyyy,getdate()) and 1.sales_date<= getdate() then 1.customer_id else NULL end) as float)/ cast (count(distinct case when datepart(yyyy,1.sales_date)=datepart(yyyy,getdate())-1 and datepart(dy,1.sales_date)<=datepart(dy,getdate()) then 1.customer_id else NULL end) as float))-10ytd_c0qf›_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&7~&0~&0~&-1~&-1~&-1~&-1~&T[0]T[ds]T[0]T[0]L[ %]T[pc]~&~&~&~&~&~&~&NF_~&SIMSTY_~&+"> Quarterly E÷° QTD Salesľsum(case when datepart(yyyy,1.sales_date)=datepart(yyyy,getdate()) and datepart(q,1.sales_date)=datepart(q,getdate()) and 1.sales_date<= getdate() then 1.store_sales else 0 end)0mtd_s051ląPrevious Year QTD SalesÎsum(case when datepart(yyyy,1.sales_date)=datepart(yyyy,getdate())-1 and datepart(q,1.sales_date)=datepart(q,getdate()) and datepart(d,1.sales_date)<=datepart(d,getdate()) then 1.store_sales else 0 end)0lymtd052-߲ QTD Sales less Prev Yr QTD Sales†sum(case when datepart(yyyy,1.sales_date)=datepart(yyyy,getdate()) and datepart(q,1.sales_date)=datepart(q,getdate()) and 1.sales_date<= getdate() then 1.store_sales else 0 end) - sum(case when datepart(yyyy,1.sales_date)=datepart(yyyy,getdate())-1 and datepart(q,1.sales_date)=datepart(q,getdate()) and datepart(d,1.sales_date)<=datepart(d,getdate()) then 1.store_sales else 0 end)0objec053šĐ QTD Sales vs Prev Yr QTD Sales %wcase when sum(case when datepart(yyyy,1.sales_date)=datepart(yyyy,getdate())-1 and datepart(q,1.sales_date)=datepart(q,getdate()) and datepart(d,1.sales_date)<=datepart(d,getdate()) then 1.store_sales else 0 end) = 0 then 0 else (sum(case when datepart(yyyy,1.sales_date)=datepart(yyyy,getdate()) and datepart(q,1.sales_date)=datepart(q,getdate()) and 1.sales_date<= getdate() then 1.store_sales else 0 end) / sum(case when datepart(yyyy,1.sales_date)=datepart(yyyy,getdate())-1 and datepart(q,1.sales_date)=datepart(q,getdate()) and datepart(d,1.sales_date)<=datepart(d,getdate()) then 1.store_sales else 0 end))-1 end0qtd_s0mt›_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&7~&0~&0~&-1~&-1~&-1~&-1~&T[0]T[ds]T[0]T[0]L[ %]T[pc]~&~&~&~&~&~&~&NF_~&SIMSTY_~&đ˘łPrevious Quarter TD SalesPsum(case when case when datepart(q,getdate())=1 then 4 else datepart(q,getdate())-1 end = datepart(q,1.sales_date) and case when datepart(q,getdate())=1 then datepart(yyyy,getdate())-1 else datepart(yyyy,getdate()) end = datepart(yyyy,1.sales_date) and datepart(d,1.sales_date)<=datepart(d,getdate()) then 1.store_sales else 0 end)0lmtd_054Ża´ QTD Sales less Prev Qtr TD Salessum(case when datepart(yyyy,1.sales_date)=datepart(yyyy,getdate()) and datepart(q,1.sales_date)=datepart(q,getdate()) and 1.sales_date<= getdate() then 1.store_sales else 0 end) - sum(case when case when datepart(q,getdate())=1 then 4 else datepart(q,getdate())-1 end = datepart(q,1.sales_date) and case when datepart(q,getdate())=1 then datepart(yyyy,getdate())-1 else datepart(yyyy,getdate()) end = datepart(yyyy,1.sales_date) and datepart(d,1.sales_date)<=datepart(d,getdate()) then 1.store_sales else 0 end)0mtd_s055˝Ô QTD Sales vs Prev Qtr TD Sales %{case when sum(case when case when datepart(q,getdate())=1 then 4 else datepart(q,getdate())-1 end = datepart(q,1.sales_date) and case when datepart(q,getdate())=1 then datepart(yyyy,getdate())-1 else datepart(yyyy,getdate()) end = datepart(yyyy,1.sales_date) and datepart(d,1.sales_date)<=datepart(d,getdate()) then 1.store_sales else 0 end) = 0 then 0 else (sum(case when datepart(yyyy,1.sales_date)=datepart(yyyy,getdate()) and datepart(q,1.sales_date)=datepart(q,getdate()) and 1.sales_date<= getdate() then 1.store_sales else 0 end) / sum(case when case when datepart(q,getdate())=1 then 4 else datepart(q,getdate())-1 end = datepart(q,1.sales_date) and case when datepart(q,getdate())=1 then datepart(yyyy,getdate())-1 else datepart(yyyy,getdate()) end = datepart(yyyy,1.sales_date) and datepart(d,1.sales_date)<=datepart(d,getdate()) then 1.store_sales else 0 end))-1 end0qtd_s0ms›_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&7~&0~&0~&-1~&-1~&-1~&-1~&T[0]T[ds]T[0]T[0]L[ %]T[pc]~&~&~&~&~&~&~&NF_~&SIMSTY_~&¸jľPrevious Quarter Salessum(case when case when datepart(q,getdate())=1 then 4 else datepart(q,getdate())-1 end = datepart(q,1.sales_date) and case when datepart(q,getdate())=1 then datepart(yyyy,getdate())-1 else datepart(yyyy,getdate()) end = datepart(yyyy,1.sales_date) then 1.store_sales else 0 end)0lm_sa056ÂtžPrevious Quarter Prev Yr Salessum(case when case when datepart(q,getdate())=1 then 4 else datepart(q,getdate())-1 end = datepart(q,1.sales_date) and case when datepart(q,getdate())=1 then datepart(yyyy,getdate())-2 else datepart(yyyy,getdate())-1 end = datepart(yyyy,1.sales_date) then 1.store_sales else 0 end)0previ05fn D)4 Quarter Sales‰†MQ1Ksum(case when datepart(q,1.sales_date) = 1 then 1.store_sales else 0 end)0janua0o5ľ_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&769~&STY_~&_STYFIELDS~&769~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&4~&0~&0~&-1~&2~&-1~&-1~&L[$]T[#]T[gs]T[#]T[#]T[0]~&L[$]T[-]T[#]T[gs]T[#]T[#]T[0]~&~&~&~&~&~&NF_~&SIMSTY_~&‡†NQ2Ksum(case when datepart(q,1.sales_date) = 2 then 1.store_sales else 0 end)0q120o6ľ_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&769~&STY_~&_STYFIELDS~&769~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&4~&0~&0~&-1~&2~&-1~&-1~&L[$]T[#]T[gs]T[#]T[#]T[0]~&L[$]T[-]T[#]T[gs]T[#]T[#]T[0]~&~&~&~&~&~&NF_~&SIMSTY_~&‡†OQ3Ksum(case when datepart(q,1.sales_date) = 3 then 1.store_sales else 0 end)0q220o7ľ_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&769~&STY_~&_STYFIELDS~&769~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&4~&0~&0~&-1~&2~&-1~&-1~&L[$]T[#]T[gs]T[#]T[#]T[0]~&L[$]T[-]T[#]T[gs]T[#]T[#]T[0]~&~&~&~&~&~&NF_~&SIMSTY_~&‡†PQ4Ksum(case when datepart(q,1.sales_date) = 4 then 1.store_sales else 0 end)0q320o8ľ_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&769~&STY_~&_STYFIELDS~&769~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&4~&0~&0~&-1~&2~&-1~&-1~&L[$]T[#]T[gs]T[#]T[#]T[0]~&L[$]T[-]T[#]T[gs]T[#]T[#]T[0]~&~&~&~&~&~&NF_~&SIMSTY_~&Ł@<Monthly ŕů  MTD Salesˇsum(case when datepart(yyyy,1.sales_date)=datepart(yyyy,getdate()) and datepart(mm,1.sales_date)=datepart(mm,getdate()) and 1.sales_date<= getdate() then 1.store_sales else 0 end)0ytd_s04k™_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&4~&0~&0~&-1~&-1~&-1~&-1~&L[$]T[#]T[gs]T[#]T[#]T[0]~&~&~&~&~&~&~&NF_~&SIMSTY_~&n ˘Previous Year MTD SalesĐsum(case when datepart(yyyy,1.sales_date)=datepart(yyyy,getdate())-1 and datepart(mm,1.sales_date)=datepart(mm,getdate()) and datepart(d,1.sales_date)<=datepart(d,getdate()) then 1.store_sales else 0 end)0mtd_s04mć㼠MTD Sales less Prev Yr MTD SalesŠsum(case when datepart(yyyy,1.sales_date)=datepart(yyyy,getdate()) and datepart(mm,1.sales_date)=datepart(mm,getdate()) and 1.sales_date<= getdate() then 1.store_sales else 0 end) - sum(case when datepart(yyyy,1.sales_date)=datepart(yyyy,getdate())-1 and datepart(mm,1.sales_date)=datepart(mm,getdate()) and datepart(d,1.sales_date)<=datepart(d,getdate()) then 1.store_sales else 0 end)0mtd_s04pľ_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&4~&0~&0~&-1~&2~&-1~&-1~&L[$]T[#]T[gs]T[#]T[#]T[0]~&L[$]T[-]T[#]T[gs]T[#]T[#]T[0]~&~&~&~&~&~&NF_~&SIMSTY_~&żÖ  MTD Sales vs Prev Yr MTD Sales %}case when sum(case when datepart(yyyy,1.sales_date)=datepart(yyyy,getdate())-1 and datepart(mm,1.sales_date)=datepart(mm,getdate()) and datepart(d,1.sales_date)<=datepart(d,getdate()) then 1.store_sales else 0 end) = 0 then 0 else (sum(case when datepart(yyyy,1.sales_date)=datepart(yyyy,getdate()) and datepart(mm,1.sales_date)=datepart(mm,getdate()) and 1.sales_date<= getdate() then 1.store_sales else 0 end) / sum(case when datepart(yyyy,1.sales_date)=datepart(yyyy,getdate())-1 and datepart(mm,1.sales_date)=datepart(mm,getdate()) and datepart(d,1.sales_date)<=datepart(d,getdate()) then 1.store_sales else 0 end))-1 end0mtd_s0mu›_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&7~&0~&0~&-1~&-1~&-1~&-1~&T[0]T[ds]T[0]T[0]L[ %]T[pc]~&~&~&~&~&~&~&NF_~&SIMSTY_~&sĽ§Previous Month TD SalesUsum(case when case when datepart(mm,getdate())=1 then 12 else datepart(mm,getdate())-1 end = datepart(mm,1.sales_date) and case when datepart(mm,getdate())=1 then datepart(yyyy,getdate())-1 else datepart(yyyy,getdate()) end = datepart(yyyy,1.sales_date) and datepart(d,1.sales_date)<=datepart(d,getdate()) then 1.store_sales else 0 end)0mtd_s04r€_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&257~&STY_~&_STYFIELDS~&257~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&0~&0~&0~&-1~&-1~&-1~&-1~&~&~&~&~&~&~&~&NF_~&SIMSTY_~&mj¨"MTD Sales less Prev Month TD Salessum(case when datepart(yyyy,1.sales_date)=datepart(yyyy,getdate()) and datepart(mm,1.sales_date)=datepart(mm,getdate()) and 1.sales_date<= getdate() then 1.store_sales else 0 end) - sum(case when case when datepart(mm,getdate())=1 then 12 else datepart(mm,getdate())-1 end = datepart(mm,1.sales_date) and case when datepart(mm,getdate())=1 then datepart(yyyy,getdate())-1 else datepart(yyyy,getdate()) end = datepart(yyyy,1.sales_date) and datepart(d,1.sales_date)<=datepart(d,getdate()) then 1.store_sales else 0 end)0mtd_s04sľ_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&769~&STY_~&_STYFIELDS~&769~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&4~&0~&0~&-1~&2~&-1~&-1~&L[$]T[#]T[gs]T[#]T[#]T[0]~&L[$]T[-]T[#]T[gs]T[#]T[#]T[0]~&~&~&~&~&~&NF_~&SIMSTY_~&Ëâ""MTD Sales vs Prev Month TD Sales %‡case when sum(case when case when datepart(mm,getdate())=1 then 12 else datepart(mm,getdate())-1 end = datepart(mm,1.sales_date) and case when datepart(mm,getdate())=1 then datepart(yyyy,getdate())-1 else datepart(yyyy,getdate()) end = datepart(yyyy,1.sales_date) and datepart(d,1.sales_date)<=datepart(d,getdate()) then 1.store_sales else 0 end) = 0 then 0 else (sum(case when datepart(yyyy,1.sales_date)=datepart(yyyy,getdate()) and datepart(mm,1.sales_date)=datepart(mm,getdate()) and 1.sales_date<= getdate() then 1.store_sales else 0 end) / sum(case when case when datepart(mm,getdate())=1 then 12 else datepart(mm,getdate())-1 end = datepart(mm,1.sales_date) and case when datepart(mm,getdate())=1 then datepart(yyyy,getdate())-1 else datepart(yyyy,getdate()) end = datepart(yyyy,1.sales_date) and datepart(d,1.sales_date)<=datepart(d,getdate()) then 1.store_sales else 0 end))-1 end0mtd_s0mw›_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&769~&STY_~&_STYFIELDS~&769~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&7~&0~&0~&-1~&-1~&-1~&-1~&T[0]T[ds]T[0]T[0]L[ %]T[pc]~&~&~&~&~&~&~&NF_~&SIMSTY_~&TmŚPrevious Month Sales sum(case when case when datepart(mm,getdate())=1 then 12 else datepart(mm,getdate())-1 end = datepart(mm,1.sales_date) and case when datepart(mm,getdate())=1 then datepart(yyyy,getdate())-1 else datepart(yyyy,getdate()) end = datepart(yyyy,1.sales_date) then 1.store_sales else 0 end)0mtd_s04q™_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&4~&0~&0~&-1~&-1~&-1~&-1~&L[$]T[#]T[gs]T[#]T[#]T[0]~&~&~&~&~&~&~&NF_~&SIMSTY_~&`y˝Previous Month Last Year Sales"sum(case when case when datepart(mm,getdate())=1 then 12 else datepart(mm,getdate())-1 end = datepart(mm,1.sales_date) and case when datepart(mm,getdate())=1 then datepart(yyyy,getdate())-2 else datepart(yyyy,getdate())-1 end = datepart(yyyy,1.sales_date) then 1.store_sales else 0 end)0last_05e™_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&4~&0~&0~&-1~&-1~&-1~&-1~&L[$]T[#]T[gs]T[#]T[#]T[0]~&~&~&~&~&~&~&NF_~&SIMSTY_~&C(12 Month Sales ŒAJanuaryLsum(case when datepart(mm,1.sales_date) = 1 then 1.store_sales else 0 end)0objec0nsľ_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&769~&STY_~&_STYFIELDS~&769~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&4~&0~&0~&-1~&2~&-1~&-1~&L[$]T[#]T[gs]T[#]T[#]T[0]~&L[$]T[-]T[#]T[gs]T[#]T[#]T[0]~&~&~&~&~&~&NF_~&SIMSTY_~&BFebruaryLsum(case when datepart(mm,1.sales_date) = 2 then 1.store_sales else 0 end)0janua0ntľ_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&769~&STY_~&_STYFIELDS~&769~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&4~&0~&0~&-1~&2~&-1~&-1~&L[$]T[#]T[gs]T[#]T[#]T[0]~&L[$]T[-]T[#]T[gs]T[#]T[#]T[0]~&~&~&~&~&~&NF_~&SIMSTY_~&ŠCMarchLsum(case when datepart(mm,1.sales_date) = 3 then 1.store_sales else 0 end)0febru0nuľ_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&769~&STY_~&_STYFIELDS~&769~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&4~&0~&0~&-1~&2~&-1~&-1~&L[$]T[#]T[gs]T[#]T[#]T[0]~&L[$]T[-]T[#]T[gs]T[#]T[#]T[0]~&~&~&~&~&~&NF_~&SIMSTY_~&ŠDAprilLsum(case when datepart(mm,1.sales_date) = 4 then 1.store_sales else 0 end)0march0nvľ_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&769~&STY_~&_STYFIELDS~&769~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&4~&0~&0~&-1~&2~&-1~&-1~&L[$]T[#]T[gs]T[#]T[#]T[0]~&L[$]T[-]T[#]T[gs]T[#]T[#]T[0]~&~&~&~&~&~&NF_~&SIMSTY_~&‹ˆEMayLsum(case when datepart(mm,1.sales_date) = 5 then 1.store_sales else 0 end)0april0nwľ_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&769~&STY_~&_STYFIELDS~&769~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&4~&0~&0~&-1~&2~&-1~&-1~&L[$]T[#]T[gs]T[#]T[#]T[0]~&L[$]T[-]T[#]T[gs]T[#]T[#]T[0]~&~&~&~&~&~&NF_~&SIMSTY_~&‹‰FJuneLsum(case when datepart(mm,1.sales_date) = 6 then 1.store_sales else 0 end)0may20nxľ_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&769~&STY_~&_STYFIELDS~&769~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&4~&0~&0~&-1~&2~&-1~&-1~&L[$]T[#]T[gs]T[#]T[#]T[0]~&L[$]T[-]T[#]T[gs]T[#]T[#]T[0]~&~&~&~&~&~&NF_~&SIMSTY_~&Œ‰GJulyLsum(case when datepart(mm,1.sales_date) = 7 then 1.store_sales else 0 end)0june20nyľ_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&769~&STY_~&_STYFIELDS~&769~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&4~&0~&0~&-1~&2~&-1~&-1~&L[$]T[#]T[gs]T[#]T[#]T[0]~&L[$]T[-]T[#]T[gs]T[#]T[#]T[0]~&~&~&~&~&~&NF_~&SIMSTY_~&Ž‹HAugustLsum(case when datepart(mm,1.sales_date) = 8 then 1.store_sales else 0 end)0july20o0ľ_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&769~&STY_~&_STYFIELDS~&769~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&4~&0~&0~&-1~&2~&-1~&-1~&L[$]T[#]T[gs]T[#]T[#]T[0]~&L[$]T[-]T[#]T[gs]T[#]T[#]T[0]~&~&~&~&~&~&NF_~&SIMSTY_~&‘ŽI SeptemberLsum(case when datepart(mm,1.sales_date) = 9 then 1.store_sales else 0 end)0augus0o1ľ_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&769~&STY_~&_STYFIELDS~&769~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&4~&0~&0~&-1~&2~&-1~&-1~&L[$]T[#]T[gs]T[#]T[#]T[0]~&L[$]T[-]T[#]T[gs]T[#]T[#]T[0]~&~&~&~&~&~&NF_~&SIMSTY_~&JOctoberMsum(case when datepart(mm,1.sales_date) = 10 then 1.store_sales else 0 end)0septe0o2ľ_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&769~&STY_~&_STYFIELDS~&769~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&4~&0~&0~&-1~&2~&-1~&-1~&L[$]T[#]T[gs]T[#]T[#]T[0]~&L[$]T[-]T[#]T[gs]T[#]T[#]T[0]~&~&~&~&~&~&NF_~&SIMSTY_~&‘ŽKNovemberMsum(case when datepart(mm,1.sales_date) = 11 then 1.store_sales else 0 end)0octob0o3ľ_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&769~&STY_~&_STYFIELDS~&769~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&4~&0~&0~&-1~&2~&-1~&-1~&L[$]T[#]T[gs]T[#]T[#]T[0]~&L[$]T[-]T[#]T[gs]T[#]T[#]T[0]~&~&~&~&~&~&NF_~&SIMSTY_~&‘ŽLDecemberMsum(case when datepart(mm,1.sales_date) = 12 then 1.store_sales else 0 end)0novem0o4ľ_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&769~&STY_~&_STYFIELDS~&769~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&4~&0~&0~&-1~&2~&-1~&-1~&L[$]T[#]T[gs]T[#]T[#]T[0]~&L[$]T[-]T[#]T[gs]T[#]T[#]T[0]~&~&~&~&~&~&NF_~&SIMSTY_~&N;WeeklyPˇWeek to Date Salesˇsum(case when datepart(yyyy,1.sales_date)=datepart(yyyy,getdate()) and datepart(wk,1.sales_date)=datepart(wk,getdate()) and 1.sales_date<= getdate() then 1.store_sales else 0 end)0mtd_s058şlťPrevious Week Sales sum(case when case when datepart(wk,getdate())=1 then 52 else datepart(wk,getdate())-1 end = datepart(wk,1.sales_date) and case when datepart(wk,getdate())=1 then datepart(yyyy,getdate())-1 else datepart(yyyy,getdate()) end = datepart(yyyy,1.sales_date) then 1.store_sales else 0 end)0last_05cĆxźPrevious Week Last Year Sales"sum(case when case when datepart(wk,getdate())=1 then 52 else datepart(wk,getdate())-1 end = datepart(wk,1.sales_date) and case when datepart(wk,getdate())=1 then datepart(yyyy,getdate())-2 else datepart(yyyy,getdate())-1 end = datepart(yyyy,1.sales_date) then 1.store_sales else 0 end)0last_05d7A3 7 Days Sales‹‹USundayLsum(case when datepart(dw,1.sales_date) = 1 then 1.store_sales else 0 end)0q10odľ_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&769~&STY_~&_STYFIELDS~&769~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&4~&0~&0~&-1~&2~&-1~&-1~&L[$]T[#]T[gs]T[#]T[#]T[0]~&L[$]T[-]T[#]T[gs]T[#]T[#]T[0]~&~&~&~&~&~&NF_~&SIMSTY_~&Ž‹VMondayLsum(case when datepart(dw,1.sales_date) = 2 then 1.store_sales else 0 end)0sunda0oeľ_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&769~&STY_~&_STYFIELDS~&769~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&4~&0~&0~&-1~&2~&-1~&-1~&L[$]T[#]T[gs]T[#]T[#]T[0]~&L[$]T[-]T[#]T[gs]T[#]T[#]T[0]~&~&~&~&~&~&NF_~&SIMSTY_~&ŒWTuesdayLsum(case when datepart(dw,1.sales_date) = 3 then 1.store_sales else 0 end)0monda0ofľ_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&769~&STY_~&_STYFIELDS~&769~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&4~&0~&0~&-1~&2~&-1~&-1~&L[$]T[#]T[gs]T[#]T[#]T[0]~&L[$]T[-]T[#]T[gs]T[#]T[#]T[0]~&~&~&~&~&~&NF_~&SIMSTY_~&‘ŽX WednesdayLsum(case when datepart(dw,1.sales_date) = 4 then 1.store_sales else 0 end)0tuesd0ogľ_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&769~&STY_~&_STYFIELDS~&769~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&4~&0~&0~&-1~&2~&-1~&-1~&L[$]T[#]T[gs]T[#]T[#]T[0]~&L[$]T[-]T[#]T[gs]T[#]T[#]T[0]~&~&~&~&~&~&NF_~&SIMSTY_~&YThursdayLsum(case when datepart(dw,1.sales_date) = 5 then 1.store_sales else 0 end)0wedne0ohľ_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&769~&STY_~&_STYFIELDS~&769~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&4~&0~&0~&-1~&2~&-1~&-1~&L[$]T[#]T[gs]T[#]T[#]T[0]~&L[$]T[-]T[#]T[gs]T[#]T[#]T[0]~&~&~&~&~&~&NF_~&SIMSTY_~&Ž‹ZFridayLsum(case when datepart(dw,1.sales_date) = 6 then 1.store_sales else 0 end)0thurs0oiľ_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&769~&STY_~&_STYFIELDS~&769~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&4~&0~&0~&-1~&2~&-1~&-1~&L[$]T[#]T[gs]T[#]T[#]T[0]~&L[$]T[-]T[#]T[gs]T[#]T[#]T[0]~&~&~&~&~&~&NF_~&SIMSTY_~&[SaturdayLsum(case when datepart(dw,1.sales_date) = 7 then 1.store_sales else 0 end)0frida0ojľ_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&769~&STY_~&_STYFIELDS~&769~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&4~&0~&0~&-1~&2~&-1~&-1~&L[$]T[#]T[gs]T[#]T[#]T[0]~&L[$]T[-]T[#]T[gs]T[#]T[#]T[0]~&~&~&~&~&~&NF_~&SIMSTY_~&ˇ:Daily ÷ŠŔ Today's Salescsum(case when 1.sales_date=convert (SMALLDATETIME, {fn CURDATE()}) then 1.store_sales else 0 end)0week_05hýŻÁYesterday's Salesesum(case when 1.sales_date=convert (SMALLDATETIME, {fn CURDATE()})-1 then 1.store_sales else 0 end)0today05it&Â"Today's Sales less Yesterday SalesËsum(case when 1.sales_date=convert (SMALLDATETIME, {fn CURDATE()}) then 1.store_sales else 0 end) - sum(case when 1.sales_date=convert (SMALLDATETIME, {fn CURDATE()})-1 then 1.store_sales else 0 end)0objec05j—Ž#"Today's Sales vs Yesterday Sales %Scase when sum(case when 1.sales_date=convert (SMALLDATETIME, {fn CURDATE()})-1 then 1.store_sales else 0 end) = 0 then 0 else (sum(case when 1.sales_date=convert (SMALLDATETIME, {fn CURDATE()}) then 1.store_sales else 0 end) / sum(case when 1.sales_date=convert (SMALLDATETIME, {fn CURDATE()})-1 then 1.store_sales else 0 end))-1 end0today0mx›_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&7~&0~&0~&-1~&-1~&-1~&-1~&T[0]T[ds]T[0]T[0]L[ %]T[pc]~&~&~&~&~&~&~&NF_~&SIMSTY_~&šĂSame Day One Week Ago Salesesum(case when 1.sales_date=convert (SMALLDATETIME, {fn CURDATE()})-7 then 1.store_sales else 0 end)0today05kˇÄSame Day Year Ago Salesgsum(case when 1.sales_date=convert (SMALLDATETIME, {fn CURDATE()})-365 then 1.store_sales else 0 end)0week_05lc`uLast Days Salessum(51.Last_Days_Sales)30last_0paľ_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&4~&0~&0~&-1~&2~&-1~&-1~&L[$]T[#]T[gs]T[#]T[#]T[0]~&L[$]T[-]T[#]T[gs]T[#]T[#]T[0]~&~&~&~&~&~&NF_~&SIMSTY_~&qnvPenultimate Days Salessum(51.Penultimate_Days_Sales)30penul0pbľ_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&4~&0~&0~&-1~&2~&-1~&-1~&L[$]T[#]T[gs]T[#]T[#]T[0]~&L[$]T[-]T[#]T[gs]T[#]T[#]T[0]~&~&~&~&~&~&NF_~&SIMSTY_~&ŠwLast Day/Penultimate Day Delta3sum(51.Last_Days_Sales-51.Penultimate_Days_Sales)30last_0pcľ_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&4~&0~&0~&-1~&2~&-1~&-1~&L[$]T[#]T[gs]T[#]T[#]T[0]~&L[$]T[-]T[#]T[gs]T[#]T[#]T[0]~&~&~&~&~&~&NF_~&SIMSTY_~&´I#Prompted Periods Ago0âŮn Months Ago Sales—sum(case when datediff(m, 1.sales_date,getdate()) <= @Prompt('Months Ago','N',,mono,free) and 1.sales_date<=getdate() then 1.store_sales else 0 end)0n_wee067ÍŘn Weeks Ago Salesƒsum(case when 1.sales_date between getdate()-(@Prompt('Weeks Ago','N',,mono,free)*7) and getdate() then 1.store_sales else 0 end)0n_day066Ç×n Days Ago Sales~sum(case when 1.sales_date between getdate()-@Prompt('Days Ago','N',,mono,free) and getdate() then 1.store_sales else 0 end)0objec065XE5Rolling AveragesŤ]]Week Ending Date38.Week_Ending_Date&&"week_0ol^[^Average Weekly Salesavg(41.Sales))2sales0omľ_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&4~&0~&0~&-1~&2~&-1~&-1~&L[$]T[#]T[gs]T[#]T[#]T[0]~&L[$]T[-]T[#]T[gs]T[#]T[#]T[0]~&~&~&~&~&~&NF_~&SIMSTY_~&˜6F&Prompted Measuresď3 Measure 1nGeneric measure which prompts for the specific column to be selected and prompts for the aggregation to apply.Xcase when @Prompt('Measure 1 Rollup','A',{'Sum','Average'},mono,constrained)='Sum' then sum(case when @Prompt('Measure 1','A',{'Sales','Cost','Margin','Units'},mono,constrained)='Sales' then 1.store_sales when @Prompt('Measure 1','A',{'Sales','Cost','Margin','Units'},mono,constrained)='Margin' then 1.store_sales-1.store_cost when @Prompt('Measure 1','A',{'Sales','Cost','Margin','Units'},mono,constrained)='Units' then 1.unit_sales else 1.store_cost end) else Avg(case when @Prompt('Measure 1','A',{'Sales','Cost','Margin','Units'},mono,constrained)='Sales' then 1.store_sales when @Prompt('Measure 1','A',{'Sales','Cost','Margin','Units'},mono,constrained)='Margin' then 1.store_sales-1.store_cost when @Prompt('Measure 1','A',{'Sales','Cost','Margin','Units'},mono,constrained)='Units' then 1.unit_sales else 1.store_cost end) end0measu0ne™_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&4~&0~&0~&-1~&-1~&-1~&-1~&L[$]T[#]T[gs]T[#]T[#]T[0]~&~&~&~&~&~&~&NF_~&SIMSTY_~&ď4 Measure 2nGeneric measure which prompts for the specific column to be selected and prompts for the aggregation to apply.Xcase when @Prompt('Measure 2 Rollup','A',{'Sum','Average'},mono,constrained)='Sum' then sum(case when @Prompt('Measure 2','A',{'Sales','Cost','Margin','Units'},mono,constrained)='Sales' then 1.store_sales when @Prompt('Measure 2','A',{'Sales','Cost','Margin','Units'},mono,constrained)='Margin' then 1.store_sales-1.store_cost when @Prompt('Measure 2','A',{'Sales','Cost','Margin','Units'},mono,constrained)='Units' then 1.unit_sales else 1.store_cost end) else Avg(case when @Prompt('Measure 2','A',{'Sales','Cost','Margin','Units'},mono,constrained)='Sales' then 1.store_sales when @Prompt('Measure 2','A',{'Sales','Cost','Margin','Units'},mono,constrained)='Margin' then 1.store_sales-1.store_cost when @Prompt('Measure 2','A',{'Sales','Cost','Margin','Units'},mono,constrained)='Units' then 1.unit_sales else 1.store_cost end) end0measu0nf™_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&4~&0~&0~&-1~&-1~&-1~&-1~&L[$]T[#]T[gs]T[#]T[#]T[0]~&~&~&~&~&~&~&NF_~&SIMSTY_~&ţ2Sum Measure Prompt Column OnlyEGeneric measure which prompts for the specific column to be selected.{sum(case when @Prompt('Measure 1','A',{'Sales','Cost','Margin','Units'},mono,constrained)='Sales' then 1.store_sales when @Prompt('Measure 1','A',{'Sales','Cost','Margin','Units'},mono,constrained)='Margin' then 1.store_sales-1.store_cost when @Prompt('Measure 1','A',{'Sales','Cost','Margin','Units'},mono,constrained)='Units' then 1.unit_sales else 1.store_cost end)0measu0nd™_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&4~&0~&0~&-1~&-1~&-1~&-1~&L[$]T[#]T[gs]T[#]T[#]T[0]~&~&~&~&~&~&~&NF_~&SIMSTY_~& R/ Prompted Banding of Sales AmountfPrompts for the 3 bin breaks of the sales amount. Returns 4 bins, using the bin breaks in their names.“case when 1.store_sales < @Prompt('First Value','N',,mono,free) then 'Below '+cast(@Variable('First Value') as char(1)) when 1.store_sales >= @Prompt('First Value','N',,mono,free) and 1.store_sales < @Prompt('Second Value','N',,mono,free) then 'Between '+cast(@Variable('First Value') as char(1))+' and '+cast(@Variable('Second Value') as char(1)) when 1.store_sales >= @Prompt('Second Value','N',,mono,free) and 1.store_sales < @Prompt('Third Value','N',,mono,free) then 'Between '+cast(@Variable('Second Value') as char(1))+' and '+cast(@Variable('Third Value') as char(1)) else 'Greater than '+cast(@Variable('Third Value') as char(1)) End&"objec0nau ' 5#Prompted Banding of Prompted Amount0Prompts for measure, aggregation and bin breaks.› case when case when @Prompt('Measure 1','A',{'Sales','Cost','Margin','Units'},mono,constrained)='Sales' then 1.store_sales when @Prompt('Measure 1','A',{'Sales','Cost','Margin','Units'},mono,constrained)='Margin' then 1.store_sales-1.store_cost when @Prompt('Measure 1','A',{'Sales','Cost','Margin','Units'},mono,constrained)='Units' then 1.unit_sales else 1.store_cost end < @Prompt('First Value','N',,mono,free) then 'Below '+cast(@Variable('First Value') as char(1)) when case when @Prompt('Measure 1','A',{'Sales','Cost','Margin','Units'},mono,constrained)='Sales' then 1.store_sales when @Prompt('Measure 1','A',{'Sales','Cost','Margin','Units'},mono,constrained)='Margin' then 1.store_sales-1.store_cost when @Prompt('Measure 1','A',{'Sales','Cost','Margin','Units'},mono,constrained)='Units' then 1.unit_sales else 1.store_cost end >= @Prompt('First Value','N',,mono,free) and case when @Prompt('Measure 1','A',{'Sales','Cost','Margin','Units'},mono,constrained)='Sales' then 1.store_sales when @Prompt('Measure 1','A',{'Sales','Cost','Margin','Units'},mono,constrained)='Margin' then 1.store_sales-1.store_cost when @Prompt('Measure 1','A',{'Sales','Cost','Margin','Units'},mono,constrained)='Units' then 1.unit_sales else 1.store_cost end < @Prompt('Second Value','N',,mono,free) then 'Between '+cast(@Variable('First Value') as char(1))+' and '+cast(@Variable('Second Value') as char(1)) when case when @Prompt('Measure 1','A',{'Sales','Cost','Margin','Units'},mono,constrained)='Sales' then 1.store_sales when @Prompt('Measure 1','A',{'Sales','Cost','Margin','Units'},mono,constrained)='Margin' then 1.store_sales-1.store_cost when @Prompt('Measure 1','A',{'Sales','Cost','Margin','Units'},mono,constrained)='Units' then 1.unit_sales else 1.store_cost end >= @Prompt('Second Value','N',,mono,free) and case when @Prompt('Measure 1','A',{'Sales','Cost','Margin','Units'},mono,constrained)='Sales' then 1.store_sales when @Prompt('Measure 1','A',{'Sales','Cost','Margin','Units'},mono,constrained)='Margin' then 1.store_sales-1.store_cost when @Prompt('Measure 1','A',{'Sales','Cost','Margin','Units'},mono,constrained)='Units' then 1.unit_sales else 1.store_cost end < @Prompt('Third Value','N',,mono,free) then 'Between '+cast(@Variable('Second Value') as char(1))+' and '+cast(@Variable('Third Value') as char(1)) else 'Greater than '+cast(@Variable('Third Value') as char(1)) End&"promp0ng– |7Weekly Comparison6The 3 objects within are designed to be used together.DAe Focus WeekDPrompts users for a date. Summarizes sales for the preceding 7 days.ş(sum(case when 1.sales_date between dateadd(dd,-6,@Prompt('Week Ending What Date?','D',,mono,free)) and @Prompt('Week Ending What Date?','D',,mono,free) then 1.store_sales else 0 end))0weekl0otľ_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&769~&STY_~&_STYFIELDS~&769~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&4~&0~&0~&-1~&2~&-1~&-1~&L[$]T[#]T[gs]T[#]T[#]T[0]~&L[$]T[-]T[#]T[gs]T[#]T[#]T[0]~&~&~&~&~&~&NF_~&SIMSTY_~&tqf Previous WeekaPrompts users for a date. Summarizes the sales for 1 week immediately preceding the date entered.Ę(sum(case when 1.sales_date between dateadd(dd,-13,@Prompt('Week Ending What Date?','D',,mono,free)) and dateadd(dd,-7,@Prompt('Week Ending What Date?','D',,mono,free)) then 1.store_sales else 0 end))0focus0ouľ_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&769~&STY_~&_STYFIELDS~&769~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&4~&0~&0~&-1~&2~&-1~&-1~&L[$]T[#]T[gs]T[#]T[#]T[0]~&L[$]T[-]T[#]T[gs]T[#]T[#]T[0]~&~&~&~&~&~&NF_~&SIMSTY_~&WTc Weekly DeltaŠPrompts users for a date. Summarizes the difference of sales during the week entered with the sales for the week immediately preceding it.…(sum(case when 1.sales_date between dateadd(dd,-6,@Prompt('Week Ending What Date?','D',,mono,free)) and @Prompt('Week Ending What Date?','D',,mono,free) then 1.store_sales else 0 end))-(sum(case when 1.sales_date between dateadd(dd,-13,@Prompt('Week Ending What Date?','D',,mono,free)) and dateadd(dd,-7,@Prompt('Week Ending What Date?','D',,mono,free)) then 1.store_sales else 0 end))0march0orľ_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&769~&STY_~&_STYFIELDS~&769~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&4~&0~&0~&-1~&2~&-1~&-1~&L[$]T[#]T[gs]T[#]T[#]T[0]~&L[$]T[-]T[#]T[gs]T[#]T[#]T[0]~&~&~&~&~&~&NF_~&SIMSTY_~&ź }8Monthly Comparison6The 3 objects within are designed to be used together.§¤h Focus MonthIPrompts users for a date. Summarizes sales for the month that date is in.(sum(case when 1.sales_date between DATEADD(mm, DATEDIFF(mm, 0, @Prompt('Month containing this date','D',,mono,free)), 0) and dateadd(dd, - 1, dateadd(m, 1, DATEADD(mm, DATEDIFF(mm, 0, @Prompt('Month containing this date','D',,mono,free)), 0))) then 1.store_sales else 0 end))0weekl0otľ_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&769~&STY_~&_STYFIELDS~&769~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&4~&0~&0~&-1~&2~&-1~&-1~&L[$]T[#]T[gs]T[#]T[#]T[0]~&L[$]T[-]T[#]T[gs]T[#]T[#]T[0]~&~&~&~&~&~&NF_~&SIMSTY_~&ŃÎlPrevious MonthuPrompts users for a date. Summarizes sales for the entire month previous to the month that was entered at the prompt.(sum(case when 1.sales_date between dateadd(mm,-1,DATEADD(mm, DATEDIFF(mm,0,@Prompt('Month containing this date','D',,mono,free)), 0)) and dateadd(dd,-1,DATEADD(mm, DATEDIFF(mm, 0, @Prompt('Month containing this date','D',,mono,free)), 0)) then 1.store_sales else 0 end))0focus0p1ľ_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&769~&STY_~&_STYFIELDS~&769~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&4~&0~&0~&-1~&2~&-1~&-1~&L[$]T[#]T[gs]T[#]T[#]T[0]~&L[$]T[-]T[#]T[gs]T[#]T[#]T[0]~&~&~&~&~&~&NF_~&SIMSTY_~&źšm Monthly DeltaICalculates the difference between Focus Month and Previous Month Objects.*(sum(case when 1.sales_date between DATEADD(mm, DATEDIFF(mm, 0, @Prompt('Month containing this date','D',,mono,free)), 0) and dateadd(dd, - 1, dateadd(m, 1, DATEADD(mm, DATEDIFF(mm, 0, @Prompt('Month containing this date','D',,mono,free)), 0))) then 1.store_sales else 0 end))-(sum(case when 1.sales_date between dateadd(mm,-1,DATEADD(mm, DATEDIFF(mm,0,@Prompt('Month containing this date','D',,mono,free)), 0)) and dateadd(dd,-1,DATEADD(mm, DATEDIFF(mm, 0, @Prompt('Month containing this date','D',,mono,free)), 0)) then 1.store_sales else 0 end))0focus0p2ľ_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&769~&STY_~&_STYFIELDS~&769~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&4~&0~&0~&-1~&2~&-1~&-1~&L[$]T[#]T[gs]T[#]T[#]T[0]~&L[$]T[-]T[#]T[gs]T[#]T[#]T[0]~&~&~&~&~&~&NF_~&SIMSTY_~&d< BasketsœN5 Basket ID 1.basket_id&"baske01iPËBasket Set Name17.name&"name05sŞ\ĚBasket Set Last Updated 17.last_mod&"last_05tŁUNumber of Baskets 17.records&"recor0mqФEWhich Basket Sets?Y17.name in @Prompt('Which Basket Sets?','A','Baskets\Basket Set Name',multi,constrained)ëC6Basket BinningźnaNumber of Baskets in BinCount(distinct 47.basket_id)/0baske0opâ”bBinX'=> '+cast(Floor(46.Lower_Value) as char(2))+' and <='+cast(46.Upper_Value as char(2)).&"objec0oqJ;;Ratios‰#Prompt Product Department Sales Mix˝sum(case when 4.product_department in @Prompt('Which Product Departments?','A','Product Hierarchy\Product Department',multi,constrained) then 1.store_sales else 0 end)/sum(1.store_sales)0objec0pu›_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&7~&0~&0~&-1~&-1~&-1~&-1~&T[0]T[ds]T[0]T[0]L[ %]T[pc]~&~&~&~&~&~&~&NF_~&SIMSTY_~&Hj9Time §YçCommon Date Ranges26.Date_Range&"date_06l*V:Prompted Time DimensionLGeneric object which prompts for the specific time dimension to be selected.şcase when @Prompt('Select a Time Level','A',{'Year','Year & Quarter','Year & Month','Year & Week','Date'},mono,constrained)='Year' then cast(datepart(yyyy,1.sales_date) as char(4)) when @Prompt('Select a Time Level','A',{'Year','Year & Quarter','Year & Month','Year & Week','Date'},mono,constrained)='Year & Quarter' then cast(datepart(yyyy,1.sales_date) as char(4)) +'-Q'+ cast(datepart(q,1.sales_date) as char(1)) when @Prompt('Select a Time Level','A',{'Year','Year & Quarter','Year & Month','Year & Week','Date'},mono,constrained)='Year & Month' then cast(datepart(yyyy,1.sales_date) as char(4)) + case when datepart(mm,1.sales_date)<10 then '-0'+cast(datepart(mm,1.sales_date) as char(1)) else '-'+cast(datepart(mm,1.sales_date) as char(2)) end when @Prompt('Select a Time Level','A',{'Year','Year & Quarter','Year & Month','Year & Week','Date'},mono,constrained)='Year & Week' then cast(datepart(yyyy,1.sales_date) as char(4)) + case when datepart(wk,1.sales_date)<10 then '-0'+cast(datepart(wk,1.sales_date) as char(1)) else '-'+cast(datepart(wk,1.sales_date) as char(2)) end else cast(datepart(yyyy,1.sales_date) as char(4)) + case when datepart(mm,1.sales_date)<10 then '-0'+cast(datepart(mm,1.sales_date) as char(1)) else '-'+cast(datepart(mm,1.sales_date) as char(2)) end + case when datepart(d,1.sales_date)<10 then '-0'+cast(datepart(d,1.sales_date) as char(1)) else '-'+cast(datepart(d,1.sales_date) as char(2)) end end&"promp0nl†_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&4~&0~&0~&-1~&-1~&-1~&-1~&$#,##0~&~&~&~&~&~&~&NF_~&SIMSTY_~&é›ÚWeek Day/Week EndQcase when datepart(dw,1.sales_date) in (1,7) then 'Week End' else 'Week Day' end&"objec068ŻŞ4Which Date Ranges?_26.Date_Range in @Prompt('Which Date Ranges?','A','Time\Common Date Ranges',multi,constrained)á9,YearAr–YearThe Year-cast(datepart(yyyy,1.sales_date) as char(4))&"sales04a_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&3~&0~&0~&-1~&-1~&-1~&-1~&0~&~&~&~&~&~&~&NF_~&SIMSTY_~&X†ŠMax Year$The Latest Year. This is an integer.!max(datepart(yyyy,1.sales_date))' year20pv„_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&3~&0~&0~&-1~&-1~&-1~&-1~&T[0]~&~&~&~&~&~&~&NF_~&SIMSTY_~&˜ Year to DateSdatepart(yyyy,1.sales_date)=datepart(yyyy,getdate()) and 1.sales_date<= getdate()˝¸Last Year to Datendatepart(yyyy,1.sales_date)=datepart(yyyy,getdate())-1 and datepart(dy,1.sales_date)<=datepart(dy,getdate())¨Ł#Prompt Sales YearYdatepart(yyyy,1.sales_date)=@Prompt('Transaction Year','N','Year\Year',mono,constrained)×<-Quarterˇ˜Year & QuarterYear and Quarter`cast(datepart(yyyy,1.sales_date) as char(4)) +'-Q'+ cast(datepart(q,1.sales_date) as char(1)) &"sales04cÜ× Current Quarter to Date‡datepart(yyyy,1.sales_date)=datepart(yyyy,getdate()) and datepart(q,1.sales_date)=datepart(q,getdate()) and 1.sales_date<= getdate()to Last Quarter to Date"case when datepart(q,getdate())=1 then 4 else datepart(q,getdate())-1 end = datepart(q,1.sales_date) and case when datepart(q,getdate())=1 then datepart(yyyy,getdate())-1 else datepart(yyyy,getdate()) end = datepart(yyyy,1.sales_date) and datepart(d,1.sales_date)<=datepart(d,getdate())72 Last Quarterícase when datepart(q,getdate())=1 then 4 else datepart(q,getdate())-1 end = datepart(q,1.sales_date) and case when datepart(q,getdate())=1 then datepart(yyyy,getdate())-1 else datepart(yyyy,getdate()) end = datepart(yyyy,1.sales_date)ýQuarter for Data Point DrillingĽdatepart(yyyy,1.sales_date)=datepart(yyyy,@Prompt('CURRENT_DATE','D',,mono,free)) and datepart(q,1.sales_date) = datepart(q,@Prompt('CURRENT_DATE','D',,mono,free))Ă :.Month Y — Year & MonthĆcast(datepart(yyyy,1.sales_date) as char(4)) + case when datepart(mm,1.sales_date)<10 then '-0'+cast(datepart(mm,1.sales_date) as char(1)) else '-'+cast(datepart(mm,1.sales_date) as char(2)) end&"sales04bbŸYear Month IntegerÎcast(cast(datepart(yyyy,1.sales_date) as char(4)) + case when datepart(mm,1.sales_date)<10 then '0'+cast(datepart(mm,1.sales_date) as char(1)) else+cast(datepart(mm,1.sales_date) as char(2)) end as int)&"0qh7¤ Month NameBShows month number and month name with proper sorting capabilities˛case when datepart(mm,1.sales_date)<10 then '0'+cast(datepart(mm,1.sales_date) as char(1)) else cast(datepart(mm,1.sales_date) as char(2)) end + '-'+datename(mm,1.sales_date)&"day_o04o_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&3~&0~&0~&-1~&-1~&-1~&-1~&0~&~&~&~&~&~&~&NF_~&SIMSTY_~&ÔĎ Month to Date‰datepart(yyyy,1.sales_date)=datepart(yyyy,getdate()) and datepart(mm,1.sales_date)=datepart(mm,getdate()) and 1.sales_date<= getdate()÷ňLast Year Month to Date˘datepart(yyyy,1.sales_date)=datepart(yyyy,getdate())-1 and datepart(mm,1.sales_date)=datepart(mm,getdate()) and datepart(d,1.sales_date)<=datepart(d,getdate())˙I Current Month This Year and LastŚdatepart(m,1.sales_date)=datepart(m,getdate()) and (datepart(yyyy,1.sales_date)=datepart(yyyy,getdate()) or datepart(yyyy,1.sales_date)=datepart(yyyy,getdate())-1):5 Last Monthňcase when datepart(mm,getdate())=1 then 12 else datepart(mm,getdate())-1 end = datepart(mm,1.sales_date) and case when datepart(mm,getdate())=1 then datepart(yyyy,getdate())-1 else datepart(yyyy,getdate()) end = datepart(yyyy,1.sales_date)wrLast Month to Date'case when datepart(mm,getdate())=1 then 12 else datepart(mm,getdate())-1 end = datepart(mm,1.sales_date) and case when datepart(mm,getdate())=1 then datepart(yyyy,getdate())-1 else datepart(yyyy,getdate()) end = datepart(yyyy,1.sales_date) and datepart(d,1.sales_date)<=datepart(d,getdate())ýMonth for Data Point Drilling§datepart(yyyy,1.sales_date)=datepart(yyyy,@Prompt('CURRENT_DATE','D',,mono,free)) and datepart(mm,1.sales_date) = datepart(mm,@Prompt('CURRENT_DATE','D',,mono,free))4/\Within the MonthRReceives any date as input and finds all sales activity for the month of that date”1.sales_date between @Prompt('T','D',,mono,free) and dateadd(dd, - 1, dateadd(m, 1, DATEADD(mm, DATEDIFF(mm, 0, @Prompt('T','D',,mono,free)), 0))) " 9/Week X ż Year & WeekĆcast(datepart(yyyy,1.sales_date) as char(4)) + case when datepart(wk,1.sales_date)<10 then '-0'+cast(datepart(wk,1.sales_date) as char(1)) else '-'+cast(datepart(wk,1.sales_date) as char(2)) end&"year_05g1_­ Week of Yeardatepart(wk,1.sales_date)&"day_o04x„_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&3~&0~&0~&-1~&-1~&-1~&-1~&T[0]~&~&~&~&~&~&~&NF_~&SIMSTY_~&ًŽWeek of QuarterC(datepart(wk,1.sales_date)-1)+1-(13*(datepart(q,1.sales_date)-1))&"objec04y7e? Week of Month(datepart(d,1.sales_date)/7)+1&"day_o0nq„_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&3~&0~&0~&-1~&-1~&-1~&-1~&T[0]~&~&~&~&~&~&~&NF_~&SIMSTY_~&ŰÖ Current Week to Date‰datepart(yyyy,1.sales_date)=datepart(yyyy,getdate()) and datepart(wk,1.sales_date)=datepart(wk,getdate()) and 1.sales_date<= getdate()94 Last Weekňcase when datepart(wk,getdate())=1 then 52 else datepart(wk,getdate())-1 end = datepart(wk,1.sales_date) and case when datepart(wk,getdate())=1 then datepart(yyyy,getdate())-1 else datepart(yyyy,getdate()) end = datepart(yyyy,1.sales_date)vqLast Week to Date'case when datepart(wk,getdate())=1 then 52 else datepart(wk,getdate())-1 end = datepart(mm,1.sales_date) and case when datepart(wk,getdate())=1 then datepart(yyyy,getdate())-1 else datepart(yyyy,getdate()) end = datepart(yyyy,1.sales_date) and datepart(d,1.sales_date)<=datepart(d,getdate())´Ż Last 7 Daysk1.sales_date between convert (SMALLDATETIME, {fn CURDATE()})-7 and convert (SMALLDATETIME, {fn CURDATE()})üWeek for Data Point Drilling§datepart(yyyy,1.sales_date)=datepart(yyyy,@Prompt('CURRENT_DATE','D',,mono,free)) and datepart(wk,1.sales_date) = datepart(wk,@Prompt('CURRENT_DATE','D',,mono,free))Ď'80Day˜JęDate 1.sales_date&"objec06owŸ4 Sales Date\cast(datepart(yyyy,1.sales_date) as char(4)) + case when datepart(mm,1.sales_date)<10 then '-0'+cast(datepart(mm,1.sales_date) as char(1)) else '-'+cast(datepart(mm,1.sales_date) as char(2)) end + case when datepart(d,1.sales_date)<10 then '-0'+cast(datepart(d,1.sales_date) as char(1)) else '-'+cast(datepart(d,1.sales_date) as char(2)) end&"sales01hŠ_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&5~&0~&0~&-1~&-1~&-1~&-1~&mm/dd/yyyy~&~&~&~&~&~&~&NF_~&SIMSTY_~&śˆSales Date Onlynconvert(datetime,cast(datepart(yyyy,1.sales_date) as char(4)) + case when datepart(mm,1.sales_date)<10 then '-0'+cast(datepart(mm,1.sales_date) as char(1)) else '-'+cast(datepart(mm,1.sales_date) as char(2)) end + case when datepart(d,1.sales_date)<10 then '-0'+cast(datepart(d,1.sales_date) as char(1)) else '-'+cast(datepart(d,1.sales_date) as char(2)) end)&"sales0pt™_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&5~&0~&0~&-1~&-1~&-1~&-1~&T[0M]T[da]T[0d]T[da]T[y4]~&~&~&~&~&~&~&NF_~&SIMSTY_~&ČzÖFirst Date of Month.DATEADD(mm, DATEDIFF(mm, 0, 1.sales_date), 0)&"objec064íŸ+Last Date of the MonthPdateadd(dd, - 1, dateadd(m, 1, DATEADD(mm, DATEDIFF(mm, 0, 1.sales_date), 0))) &"date20n6ۍ(First Date Previous Month;dateadd(mm,-1,DATEADD(mm, DATEDIFF(mm,0,1.sales_date), 0))&"date20n3܎'Last Date Previous Month=dateadd(dd,-1,DATEADD(mm, DATEDIFF(mm, 0, 1.sales_date), 0))&"date20n2ߑ)First Date Previous Quarter=dateadd(qq,-1,DATEADD(qq, DATEDIFF(qq,0,1.sales_date), 0)) &"date20n4ۍ*Last Date Previous Quarter:dateadd(d,-1,DATEADD(qq, DATEDIFF(qq,0,1.sales_date), 0))&"date20n5Čz„First Date of Quarter,DATEADD(qq, DATEDIFF(qq,0,1.sales_date), 0)&"objec0ppĘ|ƒLast Date of Quarter/DATEADD(qq, DATEDIFF(qq,-1,1.sales_date), 0)-1&"objec0poÉ{‡First Date of the Year,DATEADD(yy, DATEDIFF(yy,0,1.sales_date), 0)&"objec0psۍ†Last Date of the Year?dateadd(ms,-3,DATEADD(yy, DATEDIFF(yy,0,1.sales_date )+1, 0))&"objec0pr؏ First Date of Previous Year;dateadd(yy,-1,DATEADD(yy, DATEDIFF(yy,0,1.sales_date), 0))&"0qiĽWS Maximum Datemax(1.sales_date)' objec0ob>Wä Minimum Datemin(1.sales_date)' sales06i™_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&5~&0~&0~&-1~&-1~&-1~&-1~&T[0M]T[da]T[0d]T[da]T[y4]~&~&~&~&~&~&~&NF_~&SIMSTY_~&ĆxŇWeek Ending Date/(1.sales_date - DATEPART(dw, 1.sales_date))+7&"objec060у,Week Beginning Airline Date/(1.sales_date - DATEPART(dw, 1.sales_date))+2&"week_0n7ąco#Day of Month, Month and Day of Weekcase when datepart(d,Current_Facts.sales_date)<10 then '0'+cast(datepart(d,Current_Facts.sales_date) as char(1)) else cast(datepart(d,Current_Facts.sales_date) as char(2)) end+' '+left(datename(m,Current_Facts.sales_date),3)+' '+left(datename(dw,1.sales_date),3)&"date20p4xsToday51.sales_date=convert (SMALLDATETIME, {fn CURDATE()})~y Yesterday71.sales_date=convert (SMALLDATETIME, {fn CURDATE()})-1‹KLast DayLast DayB1.sales_date = (select max(1.sales_date) from dbo.Current_Facts)PKJPenultimate Day7The second to last day in a series of transaction datesĚ1.sales_date = (select min(Last_Two_Dates.Last_Two_Dates) from (select distinct top 2 Current_Facts.sales_date as Last_Two_Dates from Current_Facts order by Current_Facts.sales_date desc) Last_Two_Dates)‡‚Same Day Last Week71.sales_date=convert (SMALLDATETIME, {fn CURDATE()})-7śą Last 30 Daysl1.sales_date between convert (SMALLDATETIME, {fn CURDATE()})-30 and convert (SMALLDATETIME, {fn CURDATE()})oj Week Days(datepart(dw,1.sales_date) not in (1,7) kf Week Ends$datepart(dw,1.sales_date) in (1,7) { K1Relative Day of Period0^œ Day of Yeardatepart(dy,1.sales_date)&"sales04g„_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&3~&0~&0~&-1~&-1~&-1~&-1~&T[0]~&~&~&~&~&~&~&NF_~&SIMSTY_~&łeŻDay of Quartercase when datepart(q,1.sales_date) = 2 then (datepart(dy,1.sales_date))-(90*(datepart(q,1.sales_date)-1)) when datepart(q,1.sales_date) = 3 then (datepart(dy,1.sales_date))-(90*(datepart(q,1.sales_date)-1)) else (datepart(dy,1.sales_date))-(91*(datepart(q,1.sales_date)-1)) end&"week_0500^ Day of Monthdatepart(d,1.sales_date)&"day_o04h„_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&3~&0~&0~&-1~&-1~&-1~&-1~&T[0]~&~&~&~&~&~&~&NF_~&SIMSTY_~&ež Day of WeekIcast(datepart(dw,1.sales_date) as char(1))+'-'+datename(w,1.sales_date)&"day_o04iŠ_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&5~&0~&0~&-1~&-1~&-1~&-1~&mm/dd/yyyy~&~&~&~&~&~&~&NF_~&SIMSTY_~&ŤÓ-Day of Week Airline‡case when datepart(dw,1.sales_date)=1 then '7-' else cast(datepart(dw,1.sales_date)-1 as char(1)) end +'-'+datename(dw,1.sales_date)&"day_o0n8Š_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&5~&0~&0~&-1~&-1~&-1~&-1~&mm/dd/yyyy~&~&~&~&~&~&~&NF_~&SIMSTY_~&(F"Relative Time Ago HeĐDays Ago$datediff(d,1.sales_date, getdate())&"objec05x•_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&3~&0~&0~&-1~&-1~&-1~&-1~&T[#]T[gs]T[#]T[#]T[0]~&~&~&~&~&~&~&NF_~&SIMSTY_~&JgŃ Weeks Ago%datediff(wk,1.sales_date, getdate())&"days_05y•_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&3~&0~&0~&-1~&-1~&-1~&-1~&T[#]T[gs]T[#]T[#]T[0]~&~&~&~&~&~&~&NF_~&SIMSTY_~&JgÓ Months Ago$datediff(m,1.sales_date, getdate())&"weeks061•_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&3~&0~&0~&-1~&-1~&-1~&-1~&T[#]T[gs]T[#]T[#]T[0]~&~&~&~&~&~&~&NF_~&SIMSTY_~&LiÔ Quarters Ago$datediff(q,1.sales_date, getdate())&"month062•_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&3~&0~&0~&-1~&-1~&-1~&-1~&T[#]T[gs]T[#]T[#]T[0]~&~&~&~&~&~&~&NF_~&SIMSTY_~&LiŐ Years Ago'datediff(yyyy,1.sales_date, getdate())&"quart063•_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&3~&0~&0~&-1~&-1~&-1~&-1~&T[#]T[gs]T[#]T[#]T[0]~&~&~&~&~&~&~&NF_~&SIMSTY_~&ÉÄLast n Days Ago,Prompts user for number of days ago to fetchP1.sales_date between getdate()-@Prompt('Days Ago','N',,mono,free) and getdate()ĐËLast n Weeks Ago-Prompts user for number of weeks ago to fetchU1.sales_date between getdate()-(@Prompt('Weeks Ago','N',,mono,free)*7) and getdate()ćáLast n Months Ago.Prompts user for number of months ago to fetchidatediff(m, 1.sales_date,getdate()) <= @Prompt('Months Ago','N',,mono,free) and 1.sales_date<=getdate():5WLast n Months Ago Ending When>Prompts user for number of months ago from a prompted end dateĄdatediff(m, 1.sales_date,@Prompt('Ending Date','D',,mono,free)) <= @Prompt('Months Ago','N',,mono,free) and 1.sales_date<=@Prompt('Ending Date','D',,mono,free)ŁžLLast n Days Ago with activityQPrompts user for the number of days ago of activity. Skips days with no activity.÷1.sales_date >= (select min(Last_N_Dates.Last_N_Dates) from (select distinct top @Prompt('How many days of activity','N',,mono,free) Current_Facts.sales_date as Last_N_Dates from Current_Facts order by Current_Facts.sales_date desc) Last_N_Dates)—-= CustomerwrGOne Random Customer&2.customer_id = floor((10281*rand()))toHTen Random Customers49.Customer_ID=2.customer_id1 STop & Bottom N Customers:Returns the Top N Top and Bottom Customers, based on Salesy1.customer_id in (SELECT top @Prompt('How Many Customers?','N',,mono,free) 1.customer_id FROM dbo.Current_Facts GROUP BY 1.customer_id ORDER BY sum(1.store_sales) DESC ) OR 1.customer_id in (SELECT top @Prompt('How Many Customers?','N',,mono,free) 1.customer_id FROM dbo.Current_Facts GROUP BY 1.customer_id ORDER BY sum(1.store_sales) ASC ) , Top n Customers - Lifetime Sales$Prompts user for number of customers2.customer_id in (select top @Prompt('No. of Customers','N',,mono,free) customer_id from lifetime_customer_value order by lifetime_sales desc)‘Œ.!Top n Customers-Current Qtr Sales$Prompts user for number of customers2.customer_id in (select top @Prompt('No. of Customers','N',,mono,free) customer_id from quarterly_customer_facts where quarter_begin_date = ( SELECT MAX(quarter_Begin_Date) FROM quarterly_Customer_Facts WHERE quarter_Begin_Date <= GETDATE()) order by store_sales desc)‰„-#Top n Customers-Current Month Sales$Prompts user for number of customers2.customer_id in (select top @Prompt('No. of Customers','N',,mono,free) customer_id from monthly_customer_facts where month_begin_date = ( SELECT MAX(Month_Begin_Date) FROM Monthly_Customer_Facts WHERE Month_Begin_Date <= GETDATE()) order by store_sales desc)†/"Top n Customers-Current Week Sales$Prompts user for number of customers2.customer_id in (select top @Prompt('No. of Customers','N',,mono,free) customer_id from weekly_customer_facts where week_ending_date = ( SELECT MAX(week_ending_Date) FROM weekly_Customer_Facts WHERE week_ending_Date <= GETDATE()) order by store_sales desc)řó:Top n Customers-n Quarters Ago_Prompts user for number of customers and and the number of periods ago to evaluate the ranking.92.customer_id in (select top @Prompt('No. of Customers','N',,mono,free) customer_id from quarterly_customer_facts where datediff(q, quarter_begin_date,getdate()) = @Prompt('Quarters Ago','N',,mono,free) order by store_sales desc) and datediff(q,1.sales_date, getdate()) = @Prompt('Quarters Ago','N',,mono,free) îé6Top n Customers-n Months Ago_Prompts user for number of customers and and the number of periods ago to evaluate the ranking.12.customer_id in (select top @Prompt('No. of Customers','N',,mono,free) customer_id from monthly_customer_facts where datediff(m, month_begin_date,getdate()) = @Prompt('Months Ago','N',,mono,free) order by store_sales desc) and datediff(m,1.sales_date, getdate()) = @Prompt('Months Ago','N',,mono,free) ěç9Top n Customers-n Weeks Ago_Prompts user for number of customers and and the number of periods ago to evaluate the ranking.02.customer_id in (select top @Prompt('No. of Customers','N',,mono,free) customer_id from weekly_customer_facts where datediff(wk, week_ending_date,getdate()) = @Prompt('Weeks Ago','N',,mono,free) order by store_sales desc) and datediff(wk,1.sales_date, getdate()) = @Prompt('Weeks Ago','N',,mono,free) ÷ňCurrent Year CustomersŁ1.customer_id in (select distinct 1.customer_id from dbo.Current_Facts where datepart(yyyy,1.sales_date)=datepart(yyyy,getdate()) and 1.sales_date<= getdate())Ü×Previous Year Customers‡1.customer_id in (select distinct 1.customer_id from dbo.Current_Facts where datepart(yyyy,1.sales_date)=datepart(yyyy,getdate())-1) !Prompt 1st Purchase YearŻ2.customer_id in (select distinct 1.customer_id from dbo.Current_Facts where datepart(yyyy,1.sales_date)=@Prompt('Initial Purchase Year','N','Year\Year',mono,constrained) )"Prompt 2nd Purchase YearŽ2.customer_id in (select distinct 1.customer_id from dbo.Current_Facts where datepart(yyyy,1.sales_date)=@Prompt('Second Purchase Year','N','Year\Year',mono,constrained) )´@ Demographic ׉PMarital StatusBcase when 2.marital_status = 'M' then 'Married' else 'Single' end&"marit02a¤VQ Yearly Income2.yearly_income&"yearl02bÄvRGender7case when 2.gender = 'M' then 'Male' else 'Female' end&"gende02c°bSTotal Number of Children2.total_children&"total02d¸jTNumber of Children at Home2.num_children_at_home&"num_c02e˘TUEducation Level 2.education&"educa02fžPX Occupation 2.occupation&"occup02iЂY Homeowner@case when 2.houseowner = 'Y' then 'Homeowner' else 'Renter' end&"house02jŹ^ZNumber of Cars Owned2.num_cars_owned&"num_c02kÖ<Account R? Customer ID2.customer_id&"custo01sŁU@Account Number2.account_num&"accou01t RW Member Card2.member_card&"membe02hŤ]VDate Acct opened2.date_accnt_opened&"date_02g&? Geographic˜JKCountry 2.country&"count025ŚXIState Province2.state_province&"state023‘DHCity2.city&"city022 RJ Postal Code2.postal_code&"posta024šLDAddress1 2.address1&"addre01xšLEAddress2 2.address2&"addre01yšLFAddress3 2.address3&"addre020šLGAddress4 2.address4&"addre021A=PersonalŹ^Ź Customer Name2.lname + ', '+2.fname&"objec04w˜JA Last Name2.lname&"lname01u™KB First Name2.fname&"fname01v—LCMiddle Initial2.mi&"mi01wœNO Birthdate 2.birthdate&"birth029¸jŞ Customer Age%datediff(yyyy,2.birthdate,getdate())&"objec04u–HMPhone1 2.phone1&"phone027–HNPhone2 2.phone2&"phone028óFCustomer SegmentsŸRÇCustomer Set Name13.name &"name05oTĄPredictive Set Name68.nameD&"0qjŹ^ČCustomer Set Last Updated 13.last_mod &"last_05p#QŕCustomer Score 14.points&"point06e„_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&3~&0~&0~&-1~&-1~&-1~&-1~&T[0]~&~&~&~&~&~&~&NF_~&SIMSTY_~&Ź^íNumber of Customers in Set 13.records 2recor06rťmáAverage Customer Scoreavg(cast(14.points as float))0point06fš´DWhich Customer Sets?g13.name in @Prompt('Which Customer Sets?','A','Customer Segments\Customer Set Name',multi,constrained) rm(Current Members%14.edate = '2999-12-31 00:00:00.000'‘*< Product)$XWhat Product Families?Ő@Prompt('Product','A',{'All Products','Food','Drink','Non-Consumable'},mono,constrained)=4.product_family or @Prompt('Product','A',{'All Products','Food','Drink','Non-Consumable'},mono,constrained)='All Products' [Which Product Department?7Prompts user to enter a department or 'All Departments'„@Prompt('Product Department','A',,mono,free)=4.product_department or @Prompt('Product Department','A',,mono,free)='All Departments'e`UTop & Bottom N ProductsAReturns the Top N Top and Bottom Products based on Lifetime SalesË3.SKU in (SELECT Top @Prompt('How Many Products?','N',,mono,free) 3.SKU FROM dbo.Current_Facts, dbo.product WHERE ( 1.product_id=3.product_id ) GROUP BY 3.SKU ORDER BY sum(1.store_sales) DESC) or 3.SKU in (SELECT Top @Prompt('How Many Products?','N',,mono,free) 3.SKU FROM dbo.Current_Facts, dbo.product WHERE ( 1.product_id=3.product_id ) GROUP BY 3.SKU ORDER BY sum(1.store_sales) ASC) 2 Product not sold in current year§3.product_id not in (select distinct 1.product_id from dbo.Current_Facts where datepart(yyyy,1.sales_date) = datepart(yyyy,getdate()) and 1.sales_date<= getdate())@;0!Product not sold in current monthÝ3.product_id not in (select distinct 1.product_id from dbo.Current_Facts where datepart(yyyy,1.sales_date) = datepart(yyyy,getdate()) and datepart(m,1.sales_date) = datepart(m,getdate()) and 1.sales_date<= getdate())A<1 Product not sold in current weekß3.product_id not in (select distinct 1.product_id from dbo.Current_Facts where datepart(yyyy,1.sales_date) = datepart(yyyy,getdate()) and datepart(wk,1.sales_date) = datepart(wk,getdate()) and 1.sales_date<= getdate())|5!Top n Product-Current Month Sales#Prompts user for number of products˙3.product_id in (select top @Prompt('No. of Products','N',,mono,free) product_id from monthly_product_facts where month_begin_date = ( SELECT MAX(Month_Begin_Date) FROM Monthly_Product_Facts WHERE Month_Begin_Date <= GETDATE()) order by store_sales desc)čă7Top n Products-n Months Ago^Prompts user for number of products and and the number of periods ago to evaluate the ranking.-3.product_id in (select top @Prompt('No. of Products','N',,mono,free) product_id from monthly_product_facts where datediff(m, month_begin_date,getdate()) = @Prompt('Months Ago','N',,mono,free) order by store_sales desc) and datediff(m,1.sales_date, getdate()) = @Prompt('Months Ago','N',,mono,free)  8Bottom n Products-n Months Ago‡Prompts user for number of products and and the number of periods ago to evaluate the ranking. Includes only those products with sales.(3.product_id in (select top @Prompt('No. of Products','N',,mono,free) product_id from monthly_product_facts where datediff(m, month_begin_date,getdate()) = @Prompt('Months Ago','N',,mono,free) order by store_sales) and datediff(m,1.sales_date, getdate()) = @Prompt('Months Ago','N',,mono,free) ŻŞFTop 5 ProductsCSelects Top 5 products at a Store when logged on as a Store Manager1.product_id=44.Product_ID,`[M!Top N Products for Top N CustomergPrompts user for number of products, for the number of customers for a number of days of sales history.’1.customer_id=52.customer_id and 1.product_id = 53.product_id and datediff(d,1.sales_date,getdate())<=@Prompt('How Many Days','N',,mono,free)45ŕŰ^Which Products?8Prompts user to enter a Product Family or 'All Products'[@Prompt('P','A',,mono,free)=4.product_family or @Prompt('P','A',,mono,free)='All Products'× F Product Hierarchy ŚXnProduct Family4.product_family&"produ035Ž`mProduct Department4.product_department&"produ034Ş\lProduct Category4.product_category&"produ033°bkProduct Subcategory4.product_subcategory&"produ032óĽ™Generic Product NameXsubstring(3.product_name, len(3.brand_name)+2,len(3.product_name)-len(3.brand_name))&"objec04dŽB_SKU3.SKU&"sku02p T`Standard Retail Price3.SRP&"srp02qA9Prompted Product DimensionOGeneric object which prompts for the specific product dimension to be selected.›case when @Prompt('Select a Product Level','A',{'Product Family','Product Department','Product Category','Product Subcategory','Product Name'},mono,constrained)='Product Family' then 4.product_family when @Prompt('Select a Product Level','A',{'Product Family','Product Department','Product Category','Product Subcategory','Product Name'},mono,constrained)='Product Department' then 4.product_department when @Prompt('Select a Product Level','A',{'Product Family','Product Department','Product Category','Product Subcategory','Product Name'},mono,constrained)='Product Category' then 4.product_category when @Prompt('Select a Product Level','A',{'Product Family','Product Department','Product Category','Product Subcategory','Product Name'},mono,constrained)='Product Subcategory' then 4.product_subcategory else substring(3.product_name, len(3.brand_name)+2,len(3.product_name)-len(3.brand_name)) end&"sum_m0nk†_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&4~&0~&0~&-1~&-1~&-1~&-1~&$#,##0~&~&~&~&~&~&~&NF_~&SIMSTY_~&œS˘ All Products'All Products'&"0qk°HPhysical Attributes žP’ Product ID 3.product_id&"produ0q4˘Ta Gross Weight3.gross_weight&"gross02ržPb Net Weight 3.net_weight&"net_w02sŽ`cRecyclable Package3.recyclable_package&"recyc02t˜JdLow Fat 3.low_fat&"low_f02uŚXeUnits Per Case3.units_per_case&"units02vŞ\fCases Per Pallet3.cases_per_pallet&"cases02w Rg Shelf Width3.shelf_width&"shelf02x˘Th Shelf Height3.shelf_height&"shelf02y Ri Shelf Depth3.shelf_depth&"shelf030ž:BrandžP] Brand Name 3.brand_name&"brand02nŞ\^Branded Product Name3.product_name&"produ02o ; What Brands?Ç3.brand_name IN @Prompt('What Brands? (type all for all values)','A','Brand\Brand Name',multi,free) or 'all' in @Prompt('What Brands? (type all for all values)','A','Brand\Brand Name',multi,free) ‡A Product SetsžQÉProduct Set Name15.name&"name05qŤ]ĘProduct Set Last Updated 15.last_mod&"last_05r@]îNumber of Products in Set 15.records2recor06s•_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&3~&0~&0~&-1~&-1~&-1~&-1~&T[#]T[gs]T[#]T[#]T[0]~&~&~&~&~&~&~&NF_~&SIMSTY_~&ąŹ3Which Product Sets?`15.name in @Prompt('Which Product Sets?','A','Product Sets\Product Set Name',multi,constrained):Store žP€ Store Name 6.store_city&"store03n¤V‡ Store Manager6.store_manager&"store03uĘ_ Status For&The name of the user that is logged onacase when @Variable('BOUSER')=6.store_manager THEN 6.store_manager ELSE @Variable('BOUSER') end&"objec0onžP~ Store Type 6.store_type&"store03l˘T Store Number6.store_number&"store03ođë]Which Countries?JPrompts user to enter a Country Name (USA, Mexico, Canada) or 'All Stores'X@Prompt('S','A',,mono,free)=6.store_country or @Prompt('S','A',,mono,free)='All Stores'ŢŮZ Which Store?-Prompts user to enter a store or 'All Stores'g@Prompt('Store Name','A',,mono,free)=6.store_city or @Prompt('Store Name','A',,mono,free)='All Stores'ELocation Details ¤V† Store Country6.store_country&"store03t R„ Store State6.store_state&"store03ržPƒ Store City 6.store_city&"store03q˛d‚Store Street Address6.store_street_address&"store03pŹ^…Store Postal Code6.store_postal_code&"store03s Rˆ Store Phone6.store_phone&"store03vœN‰ Store Fax 6.store_fax&"store03wšL“Store ID 6.store_id&"store0q5˜OŁ All Stores 'All Stores'&"0qlYWhat Countries?Ç@Prompt('Country','A',{'All Countries','Canada','Mexico','USA'},mono,constrained)=6.store_country or @Prompt('Country','A',{'All Countries','Canada','Mexico','USA'},mono,constrained)='All Countries'S NStore Physical AttributesŞ\&Total Store Sq Ftsum(6.store_sqft)0store0n1žPŒ Lease Sqft 6.lease_sqft&"lease040žP Store Sqft 6.store_sqft&"store041˘TŽ Grocery Sqft6.grocery_sqft&"groce042 R Frozen Sqft6.frozen_sqft&"froze043œN Meat Sqft 6.meat_sqft&"meat_044žP‘ Coffee Bar 6.coffee_bar&"coffe045 R’ Video Store6.video_store&"video046œN“ Salad Bar 6.salad_bar&"salad047¤V” Prepared Food6.prepared_food&"prepa048˜J•Florist 6.florist&"flori049Ź^ŠFirst Opened Date6.first_opened_date&"first03xŹ^‹Last Remodel Date6.last_remodel_date&"last_03y˝oŠ Store Age-datediff(yyyy,6.first_opened_date,getdate())&"objec04t{> PromotionŚXqPromotion Name5.promotion_name&"promo038žPr Media Type 5.media_type&"media039KIsCost sum(5.cost)0cost03aľ_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&4~&0~&0~&-1~&2~&-1~&-1~&L[$]T[#]T[gs]T[#]T[#]T[0]~&L[$]T[-]T[#]T[gs]T[#]T[#]T[0]~&~&~&~&~&~&NF_~&SIMSTY_~&˘To Promotion ID5.promotion_id&"promo036PK r2<˝š…Z˘˘EUNW_Storage/Dynamic_Objects_Descriptions/Dynamic_Objects_DescriptionsTechnicalDescriptionMappingLineage#3?@STZoš›šÍćíî$anŽ’“”•–—žŸ Ą˘ŁPK r2ˇ5§k‹‘3ŇŒđ<¸Y!Ď.qú—hޞfs˝AÝżă<ђ°ůâ>Źěí?[Şçh<řçÖI€Б=p6—Îb"řYŢçşVŞ^q F“ lÓÓ,ANŽ_ůřX­6Ť4áźyşj> Ň!ÝĆh‡ËmŐĹ\ ´+ě1ň{ţ:Łëř;›ŕ} }ŊĄœ˝Ë˛%rp}0¸ĺ"řYŢçşVŞ^q F“ lŚK(­ŤąŠ3g%]°• ťŮ9Y}#§ ő€N ߼:Čb[ůš Óő2$Âüłz›R'Z•™˝\¤ńż—gĽkˆš”?f†@Ë^ÎşAvʖ˛ŢNďcŮÝ(ú˜‚­ lg†™—¸W€Kžéƒšüu ú‰§pľ2řđŹlŠ˙'/ń{ňč™'†}zŁňá-v°óí{Ţ ¤[d'ŕ!—'›VL€lłę[Ľkˆš”?f†@Ë^ÎşAĂűmúů‡ƒ Žz…(Œ…VÌ킦ݖšŔSpŐZɃK-%Œ†›§żÁßČŽĎó§ó&pŕŕⰞ!BĄć|!ĄB]­8šŰŹĽŐ}eĐď=ŕŠä`˜œŽ‘hÁĎń¸„]ÖćÂÎé‰ÓďĎĐ i™hźŹ( Ť—[Œ•¤M#Ă~ÁˇşKNĂőö™‰rŤ†Ń¤b‘ë]OΊĄœ˝Ë˛%rp}0¸ĺ"řYŢçşViŒň´˛RČZ›Ç— L…ůŽW8§ÝżdQͼ༽\ä‡wc âŇ#ĂŠ(`"şÉp•Ëš'ĂÎl6xŒŚ qĽ˙3řk™ „dłp^#ĽđörsŔœfl,1ŮmŚ rŮ9Y}#§ őŽJÁ‰óŞHą¤!7ĆņrFŤ†Ń¤bĽ">•Ł+ŽžŸyȅ Žc„ظƒČ^Í΁šÚ‰ç dłp^#ĽđöşžŁ(…´§‘xëńęż9}Ÿó á™ÂęĐÉđî‰{ …ůŽW8§ÝżAËÇʲśÝ€ąäĽ¤ÉŃÉíô‡Ž"ńďmߞ)Ÿëz%š&t%Łä`˜œŽ‘hÁĎń¸„]ÖćÂÎé‰Óčjcj§ĹżUřĄâ,†Ÿ—[Œ•¤M@t@ gžgťŚń,ł[vŃÉíô‡Ž"ńcÉwŠŢ1Čkh8şä`˜œŽ‘hÁĎń¸„]ÖćÂÎé‰Ó´AccäŹrźW€Kžéƒšüu ú‰§pľ2řđŹlŠ˙'/ń{ňč™'†óáâ9ˇ<ü¤ źĐĽkˆš”?f†@Ë^ÎşAÉj×ţ1žâ2äą yě[SpŐZɃK-‘m|*—ĘŢrKÇÂ0‡u‰/ń{ňč™'†ť o2á>ě%œ˙š¸Ň›dłp^#ĽđöşžŁ(…´§‘xëńęż9}!ÚËÔŁűďÚ,<ƀřŮ9Y}#§ ő€N ߼:Čb[ůš Óő2$Âüłz›R'Z•™˝\¤ńż—gĽkˆš”?f†@Ë^ÎşA5™yrô*°X0;χ›˝ó Łý¨O[v8ŢIÃŁ@Ľ >ˆ /BĄć|!ĄBěÓőľŸlŞţŢ; ÁnÓDžăťŒ @DŽŕžƒVsaŽ+Qň…ůŽW8§ÝżSü ť–ťcgW†I“0m/ń{ňč™'†óáâ9ˇť>- FoUJÁŽ6ŮCŠİ÷Ăkž°㟘ľß6uf ťýǝRŹ“Ą´x#éX&ÚËlź/ĂŻ3ŽÖŚm%kˆĂlŸMö4sŐ÷¤•l}ː1Ţžo¸n|PEꯕ‚ˆŠ†Ç6.…Œ˛e n"šgGž ŢÓ3ŽŇ`Ľš/ŤßÚą}0ť ŁŕœVřYöý„)˙˜Şä ´†xúŒ8§Łoşš>.ŚZžœ–'ĽŮ,÷Ž8€ßp¤ă‘†`ßÚą}0ť ŁŕœVúJŽö—ĂÍęČěě/ś őĂÜń"(§úM KšœŇŠ˘ülĆĎťžÖŇH˙„šî°Ť(]‘š/Ú˛ü¸ś…ql­ě–\źöĆn8”Ý.nř<ü^3…;瀽‹GtuÓˇFŠŁ*-ßöEŤ‚Â…eż¤ö(ú™Č)v[—uODĄ_Ϥƒ˝` Î<ł.=÷ÁÚT=ťK?FŮŰ+“'f ťýǝRŹ“Ą´x#éX&ÚËlź/öŽŢÄóŸç†Xčc8–ĄÄ[˜ĺ§??G“$Šä†‡˛eČ źKœąŹ$›)ÁE†ő.ß0§čnőüžŻÄx? ücžŽÇ3Úş’HýĐF„R7¤č֍‘U@­Yƒ}ː1Ţžo¸ý *Á1Ї<ÓĂů'łÁž÷ÁÚT=ťK“@l™Ť"ő4>áyŸ ü"ńMXjľô }ˇľľŤ„Š3Úş’HżO`‰’ŻPłĘuš­rÎ ’\ĎՖ‡íˇ*”"Ż !tÄ[˜ĺ§??ĐU‹Ď,R(ňyl腾Œ˝Y­źe„űœŁnÇŢłř> +p´w?}<ü^3…;瀽‹GtuÓˇFŠŁ*-Ě88§ŽÇ˙ 'ŁĺW/+ÜČ)v[—uOôiƗ„<8+lś€Ŕ˝Y­źe„űœ/Ť%žŹż¨5Żknǜ%1<ü^3…;瀽‹GtuÓˇFŠŁ*-ó#ď!œŘ÷‰@ —•51%Ľ:N™7‘dű¤€DjÝ=2Ąl>6IyI”#ŮÍü:äKľK5ßÚą}0ť ŁŕœVŐ:‚:#ş$2팋‹˛I;M KšœŇŠŽ>DËa¤Píëa4”Đ4Ý=2Ąl>ĹjŔr Z˝ZÚŤ’Ć3Úş’HżO`‰’ŻPłĘuš­rÎ c× —’˙ăvżŐĄ–Ţ}ː1Ţžo¸n|PEꯕ‚ˆŠ†Ç6.…Œ˛e n"šgGž ŢÓ3ŽŇ`Ľš/ŤßÚą}0ť ŁŕœVUşzśšŸŮLPaÇS€ŻŰQóĽ $Řč}h™Ĺ´3‘Úól<”w€Ú˛ü¸ś…qZ Í×Ň´ łJ˘’’‹ś‘s‹Ň=–Ű‘…­,ŚŽ¨ć°ĽO4ďXÄ[˜ĺ§??p3ˆôŽ|nWŻĘĹŚűÝ=2Ąl>6IyI”#ŮRŠ/_ďšŃ>I=’ó$š8s˙Đ{ƒ;Â6üƘĚBă6î  ÜĐ^ޚžňe‰#ű@ĽWPK r2 „=3 customer_id3 customer_id? ! „=3 promotion_id3 promotion_id@ " „=3store_id3store_idA % „=3 sales_date3 sales_dateB & „=3 basket_id3 basket_idC„=4 customer_id4 customer_idD„=5 product_id5 product_idH & „== customer_id= customer_idJ5455„=DE setversion_idD setversion_idEKA2AA$=4DD subject_idDL'''„=EidE customer_id`SPK r2<=júJqqTables;ED8.@Opredictive_set *02B basket_set 3 (Most_Recent_2_DaystE*'2.predictive_set_detail Ď4" Top_N_Customers)dbo.Current_Factst>"Fbasket_set_detail Ď5 "Top_N_Prod_Cust$ dbo.customer*(# dbo.product& HL Rolling_Weeks*3 dbo.product_classo"$+ dbo.promotionI-$5 dbo.store)a eWeek_Ending_Facts+H!L Monthly_Facts7"<dbo.Date_Ranges,Top_5_Products=*.Avg_Days KHSS dbo.set_set.HLInterval_Banding ahdbo.set_set_detailĎ/1H:_Basket_Summary 8(@- customer_set *1 customer_set_detail ĎA@HFL User_Prompt1*"3%Ten_Random_Customers8@& product_set B&H-MPrompted_Binning*1product_set_detail ĎPK r2<‚ĂzćÇćÇObjects;>Ł^Measures1Salessum(1.store_sales)†_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&4~&0~&0~&-1~&-1~&-1~&-1~&$#,##0~&~&~&~&~&~&~&NF_~&SIMSTY_~&store01eG0žSales Multipliersum(1.store_sales*3)†_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&4~&0~&0~&-1~&-1~&-1~&-1~&$#,##0~&~&~&~&~&~&~&NF_~&SIMSTY_~&sales0qgG06Marginsum(1.store_margin)†_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&4~&0~&0~&-1~&-1~&-1~&-1~&$#,##0~&~&~&~&~&~&~&NF_~&SIMSTY_~&store01jG02Costsum(1.store_cost)†_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&4~&0~&0~&-1~&-1~&-1~&-1~&$#,##0~&~&~&~&~&~&~&NF_~&SIMSTY_~&store01fG03 Quantity Soldsum(1.unit_sales)…_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&3~&0~&0~&-1~&-1~&-1~&-1~&#,##0~&~&~&~&~&~&~&NF_~&SIMSTY_~&unit_01gG0TTransaction Amount AboveŹ@Prompt('What Minimum?','N',,mono,free) >= case when @Prompt('What Measure?','A',{'Sales','Cost','Margin','Units'},mono,constrained) = 'Sales' then 1.store_sales when @Prompt('What Measure?','A',{'Sales','Cost','Margin','Units'},mono,constrained) = 'Cost' then 1.store_cost when @Prompt('What Measure?','A',{'Sales','Cost','Margin','Units'},mono,constrained) = 'Margin' then 1.store_margin else 1.unit_sales end*Averages şAverage Sales per Customer*Acast(sum(1.store_sales)/count(distinct 1.customer_id) as float)‰_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&4~&0~&0~&-1~&-1~&-1~&-1~&$#,##0.00~&~&~&~&~&~&~&NF_~&SIMSTY_~&objec05bG0ăAverage Sales per Basket*?cast(sum(1.store_sales)/count(distinct 1.basket_id) as float)‰_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&4~&0~&0~&-1~&-1~&-1~&-1~&$#,##0.00~&~&~&~&~&~&~&NF_~&SIMSTY_~&avera06hG0ŤAverage Price per Unit*5cast(sum(1.store_sales)/sum(1.unit_sales) as float)‰_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&4~&0~&0~&-1~&-1~&-1~&-1~&$#,##0.00~&~&~&~&~&~&~&NF_~&SIMSTY_~&objec04vG0âAverage Margin per Customer*Bcast(sum(1.store_margin)/count(distinct 1.customer_id) as float)‰_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&4~&0~&0~&-1~&-1~&-1~&-1~&$#,##0.00~&~&~&~&~&~&~&NF_~&SIMSTY_~&avera06gG0ĆAverage Margin per Basket*@cast(sum(1.store_margin)/count(distinct 1.basket_id) as float)‰_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&4~&0~&0~&-1~&-1~&-1~&-1~&$#,##0.00~&~&~&~&~&~&~&NF_~&SIMSTY_~&objec05nG0Average Margin per Item*'sum(1.store_margin)/sum(1.unit_sales)‰_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&4~&0~&0~&-1~&-1~&-1~&-1~&$#,##0.00~&~&~&~&~&~&~&NF_~&SIMSTY_~&avera0moG0Average Margin Pct*(sum(1.store_margin)/sum(1.store_sales)†_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&7~&0~&0~&-1~&-1~&-1~&-1~&0.00 %~&~&~&~&~&~&~&NF_~&SIMSTY_~&avera0mmG0Goal Margin Pct* avg(.600)†_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&7~&0~&0~&-1~&-1~&-1~&-1~&0.00 %~&~&~&~&~&~&~&NF_~&SIMSTY_~&objec0pyG0ŽPrompted Goal Pct*'avg(@Prompt('Goal Pct','N',,mono,free))†_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&7~&0~&0~&-1~&-1~&-1~&-1~&0.00 %~&~&~&~&~&~&~&NF_~&SIMSTY_~&goal_0q0G0š"Average Number of Items per Basket*\cast(cast(sum(1.unit_sales) as float)/cast(count(distinct 1.basket_id) as float) as float)ˆ_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&3~&0~&0~&-1~&-1~&-1~&-1~&#,##0.00~&~&~&~&~&~&~&NF_~&SIMSTY_~&objec05aG0Average Number of Visits*–case when count(distinct 1.customer_id) = 0 then 0 else cast(count(distinct 1.basket_id) as float)/cast(count(distinct 1.customer_id) as float) endˆ_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&3~&0~&0~&-1~&-1~&-1~&-1~&#,##0.00~&~&~&~&~&~&~&NF_~&SIMSTY_~&avera0mnG0'Avg Number of Baskets per Store per Day*ćcase when (count(distinct 1.store_id)=0 or count(distinct 1.sales_date) = 0) then 0 else (cast(count(distinct 1.basket_id) as float)/cast(count(distinct 1.store_id) as float)/cast(count(distinct 1.sales_date) as float))*6 endˆ_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&3~&0~&0~&-1~&-1~&-1~&-1~&#,##0.00~&~&~&~&~&~&~&NF_~&SIMSTY_~&avera0mpG0Avg Days*$Average Days between Customer Visits=avg(61.Avg_Days)avg_d0pmG0+CountsšNumber of Customers+count(distinct 2.customer_id)…_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&3~&0~&0~&-1~&-1~&-1~&-1~&#,##0~&~&~&~&~&~&~&NF_~&SIMSTY_~&objec04eG0nNumber of Married Customers+bCAST(count(distinct case when 2.marital_status = 'M' then 2.customer_id else NULL end) AS FLOAT)…_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&3~&0~&0~&-1~&-1~&-1~&-1~&#,##0~&~&~&~&~&~&~&NF_~&SIMSTY_~&no__o0p3G0ÍNumber of Products+count(distinct 3.product_id)…_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&3~&0~&0~&-1~&-1~&-1~&-1~&#,##0~&~&~&~&~&~&~&NF_~&SIMSTY_~&produ05uG0ćNumber of Stores+count(distinct 6.store_id)…_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&3~&0~&0~&-1~&-1~&-1~&-1~&#,##0~&~&~&~&~&~&~&NF_~&SIMSTY_~&no__o06kG0$Number of Brands+count(distinct 3.brand_name)objec0myG0>Counts from Fact Table+•Number of Customers Sold To>-cast(COUNT(DISTINCT 1.customer_id) as float)„_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&3~&0~&0~&-1~&-1~&-1~&-1~&#,##0~&~&~&~&~&~&~&NF_~&SIMSTY_~&custo0q7G0›Number of Baskets Sold>+cast(COUNT(DISTINCT 1.basket_id) as float)…_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&3~&0~&0~&-1~&-1~&-1~&-1~&#,##0~&~&~&~&~&~&~&NF_~&SIMSTY_~&baske04fG0”Number of Products Purchased>,cast(COUNT(DISTINCT 1.product_id) as float)„_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&3~&0~&0~&-1~&-1~&-1~&-1~&#,##0~&~&~&~&~&~&~&NF_~&SIMSTY_~&produ0q6G0–Number of Stores Shopped In>*cast(COUNT(DISTINCT 1.store_id) as float)„_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&3~&0~&0~&-1~&-1~&-1~&-1~&#,##0~&~&~&~&~&~&~&NF_~&SIMSTY_~&store0q8G0—Number of Promotions>.cast(COUNT(DISTINCT 1.promotion_id) as float)„_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&3~&0~&0~&-1~&-1~&-1~&-1~&#,##0~&~&~&~&~&~&~&NF_~&SIMSTY_~&promo0q9G0Time Specific MeasuresYearlyŸ YTD Salessum(case when datepart(yyyy,1.sales_date)=datepart(yyyy,getdate()) and 1.sales_date<= getdate() then 1.store_sales else 0 end)†_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&4~&0~&0~&-1~&-1~&-1~&-1~&$#,##0~&~&~&~&~&~&~&NF_~&SIMSTY_~&sales04jG0ĄPrevious Year TD Salesœsum(case when datepart(yyyy,1.sales_date)=datepart(yyyy,getdate())-1 and datepart(dy,1.sales_date)<=datepart(dy,getdate()) then 1.store_sales else 0 end)†_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&4~&0~&0~&-1~&-1~&-1~&-1~&$#,##0~&~&~&~&~&~&~&NF_~&SIMSTY_~&ytd_s04lG0ŁYTD Sales less Prev Yr TD Salessum(case when datepart(yyyy,1.sales_date)=datepart(yyyy,getdate()) and 1.sales_date<= getdate() then 1.store_sales else 0 end)-sum(case when datepart(yyyy,1.sales_date)=datepart(yyyy,getdate())-1 and datepart(dy,1.sales_date)<=datepart(dy,getdate()) then 1.store_sales else 0 end)†_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&4~&0~&0~&-1~&-1~&-1~&-1~&$#,##0~&~&~&~&~&~&~&NF_~&SIMSTY_~&ytd_s04nG0YTD Sales vs Prev Yr TD Sales %Ücase when sum(case when datepart(yyyy,1.sales_date)=datepart(yyyy,getdate())-1 and datepart(dy,1.sales_date)<=datepart(dy,getdate()) then 1.store_sales else 0 end)=0 then 0 else (sum(case when datepart(yyyy,1.sales_date)=datepart(yyyy,getdate()) and 1.sales_date<= getdate() then 1.store_sales else 0 end)/sum(case when datepart(yyyy,1.sales_date)=datepart(yyyy,getdate())-1 and datepart(dy,1.sales_date)<=datepart(dy,getdate()) then 1.store_sales else 0 end))-1 end†_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&7~&0~&0~&-1~&-1~&-1~&-1~&0.00 %~&~&~&~&~&~&~&NF_~&SIMSTY_~&ytd_s0mrG0śPrevious Year Salesesum(case when datepart(yyyy,1.sales_date)=datepart(yyyy,getdate())-1 then 1.store_sales else 0 end)†_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&4~&0~&0~&-1~&-1~&-1~&-1~&$#,##0~&~&~&~&~&~&~&NF_~&SIMSTY_~&ytd_s057G0/YTD No. Customers vs Prev Yr TD No. Customers %`(cast(count (distinct case when datepart(yyyy,1.sales_date)=datepart(yyyy,getdate()) and 1.sales_date<= getdate() then 1.customer_id else NULL end) as float)/ cast (count(distinct case when datepart(yyyy,1.sales_date)=datepart(yyyy,getdate())-1 and datepart(dy,1.sales_date)<=datepart(dy,getdate()) then 1.customer_id else NULL end) as float))-1†_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&7~&0~&0~&-1~&-1~&-1~&-1~&0.00 %~&~&~&~&~&~&~&NF_~&SIMSTY_~&ytd_c0qfG0 Quarterly ° QTD Salesľsum(case when datepart(yyyy,1.sales_date)=datepart(yyyy,getdate()) and datepart(q,1.sales_date)=datepart(q,getdate()) and 1.sales_date<= getdate() then 1.store_sales else 0 end)mtd_s051G0ąPrevious Year QTD SalesÎsum(case when datepart(yyyy,1.sales_date)=datepart(yyyy,getdate())-1 and datepart(q,1.sales_date)=datepart(q,getdate()) and datepart(d,1.sales_date)<=datepart(d,getdate()) then 1.store_sales else 0 end)lymtd052G0˛ QTD Sales less Prev Yr QTD Sales†sum(case when datepart(yyyy,1.sales_date)=datepart(yyyy,getdate()) and datepart(q,1.sales_date)=datepart(q,getdate()) and 1.sales_date<= getdate() then 1.store_sales else 0 end) - sum(case when datepart(yyyy,1.sales_date)=datepart(yyyy,getdate())-1 and datepart(q,1.sales_date)=datepart(q,getdate()) and datepart(d,1.sales_date)<=datepart(d,getdate()) then 1.store_sales else 0 end)objec053G0 QTD Sales vs Prev Yr QTD Sales %wcase when sum(case when datepart(yyyy,1.sales_date)=datepart(yyyy,getdate())-1 and datepart(q,1.sales_date)=datepart(q,getdate()) and datepart(d,1.sales_date)<=datepart(d,getdate()) then 1.store_sales else 0 end) = 0 then 0 else (sum(case when datepart(yyyy,1.sales_date)=datepart(yyyy,getdate()) and datepart(q,1.sales_date)=datepart(q,getdate()) and 1.sales_date<= getdate() then 1.store_sales else 0 end) / sum(case when datepart(yyyy,1.sales_date)=datepart(yyyy,getdate())-1 and datepart(q,1.sales_date)=datepart(q,getdate()) and datepart(d,1.sales_date)<=datepart(d,getdate()) then 1.store_sales else 0 end))-1 end†_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&7~&0~&0~&-1~&-1~&-1~&-1~&0.00 %~&~&~&~&~&~&~&NF_~&SIMSTY_~&qtd_s0mtG0łPrevious Quarter TD SalesPsum(case when case when datepart(q,getdate())=1 then 4 else datepart(q,getdate())-1 end = datepart(q,1.sales_date) and case when datepart(q,getdate())=1 then datepart(yyyy,getdate())-1 else datepart(yyyy,getdate()) end = datepart(yyyy,1.sales_date) and datepart(d,1.sales_date)<=datepart(d,getdate()) then 1.store_sales else 0 end)lmtd_054G0´ QTD Sales less Prev Qtr TD Salessum(case when datepart(yyyy,1.sales_date)=datepart(yyyy,getdate()) and datepart(q,1.sales_date)=datepart(q,getdate()) and 1.sales_date<= getdate() then 1.store_sales else 0 end) - sum(case when case when datepart(q,getdate())=1 then 4 else datepart(q,getdate())-1 end = datepart(q,1.sales_date) and case when datepart(q,getdate())=1 then datepart(yyyy,getdate())-1 else datepart(yyyy,getdate()) end = datepart(yyyy,1.sales_date) and datepart(d,1.sales_date)<=datepart(d,getdate()) then 1.store_sales else 0 end)mtd_s055G0 QTD Sales vs Prev Qtr TD Sales %{case when sum(case when case when datepart(q,getdate())=1 then 4 else datepart(q,getdate())-1 end = datepart(q,1.sales_date) and case when datepart(q,getdate())=1 then datepart(yyyy,getdate())-1 else datepart(yyyy,getdate()) end = datepart(yyyy,1.sales_date) and datepart(d,1.sales_date)<=datepart(d,getdate()) then 1.store_sales else 0 end) = 0 then 0 else (sum(case when datepart(yyyy,1.sales_date)=datepart(yyyy,getdate()) and datepart(q,1.sales_date)=datepart(q,getdate()) and 1.sales_date<= getdate() then 1.store_sales else 0 end) / sum(case when case when datepart(q,getdate())=1 then 4 else datepart(q,getdate())-1 end = datepart(q,1.sales_date) and case when datepart(q,getdate())=1 then datepart(yyyy,getdate())-1 else datepart(yyyy,getdate()) end = datepart(yyyy,1.sales_date) and datepart(d,1.sales_date)<=datepart(d,getdate()) then 1.store_sales else 0 end))-1 end†_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&7~&0~&0~&-1~&-1~&-1~&-1~&0.00 %~&~&~&~&~&~&~&NF_~&SIMSTY_~&qtd_s0msG0ľPrevious Quarter Salessum(case when case when datepart(q,getdate())=1 then 4 else datepart(q,getdate())-1 end = datepart(q,1.sales_date) and case when datepart(q,getdate())=1 then datepart(yyyy,getdate())-1 else datepart(yyyy,getdate()) end = datepart(yyyy,1.sales_date) then 1.store_sales else 0 end)lm_sa056G0žPrevious Quarter Prev Yr Salessum(case when case when datepart(q,getdate())=1 then 4 else datepart(q,getdate())-1 end = datepart(q,1.sales_date) and case when datepart(q,getdate())=1 then datepart(yyyy,getdate())-2 else datepart(yyyy,getdate())-1 end = datepart(yyyy,1.sales_date) then 1.store_sales else 0 end)previ05fG0)4 Quarter SalesMQ1)Ksum(case when datepart(q,1.sales_date) = 1 then 1.store_sales else 0 end)Œ_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&769~&STY_~&_STYFIELDS~&769~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&4~&0~&0~&-1~&2~&-1~&-1~&$#,##0~&$-#,##0~&~&~&~&~&~&NF_~&SIMSTY_~&janua0o5G0NQ2)Ksum(case when datepart(q,1.sales_date) = 2 then 1.store_sales else 0 end)Œ_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&769~&STY_~&_STYFIELDS~&769~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&4~&0~&0~&-1~&2~&-1~&-1~&$#,##0~&$-#,##0~&~&~&~&~&~&NF_~&SIMSTY_~&q120o6G0OQ3)Ksum(case when datepart(q,1.sales_date) = 3 then 1.store_sales else 0 end)Œ_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&769~&STY_~&_STYFIELDS~&769~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&4~&0~&0~&-1~&2~&-1~&-1~&$#,##0~&$-#,##0~&~&~&~&~&~&NF_~&SIMSTY_~&q220o7G0PQ4)Ksum(case when datepart(q,1.sales_date) = 4 then 1.store_sales else 0 end)Œ_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&769~&STY_~&_STYFIELDS~&769~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&4~&0~&0~&-1~&2~&-1~&-1~&$#,##0~&$-#,##0~&~&~&~&~&~&NF_~&SIMSTY_~&q320o8G0Monthly   MTD Salesˇsum(case when datepart(yyyy,1.sales_date)=datepart(yyyy,getdate()) and datepart(mm,1.sales_date)=datepart(mm,getdate()) and 1.sales_date<= getdate() then 1.store_sales else 0 end)†_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&4~&0~&0~&-1~&-1~&-1~&-1~&$#,##0~&~&~&~&~&~&~&NF_~&SIMSTY_~&ytd_s04kG0˘Previous Year MTD SalesĐsum(case when datepart(yyyy,1.sales_date)=datepart(yyyy,getdate())-1 and datepart(mm,1.sales_date)=datepart(mm,getdate()) and datepart(d,1.sales_date)<=datepart(d,getdate()) then 1.store_sales else 0 end)mtd_s04mG0Ľ MTD Sales less Prev Yr MTD SalesŠsum(case when datepart(yyyy,1.sales_date)=datepart(yyyy,getdate()) and datepart(mm,1.sales_date)=datepart(mm,getdate()) and 1.sales_date<= getdate() then 1.store_sales else 0 end) - sum(case when datepart(yyyy,1.sales_date)=datepart(yyyy,getdate())-1 and datepart(mm,1.sales_date)=datepart(mm,getdate()) and datepart(d,1.sales_date)<=datepart(d,getdate()) then 1.store_sales else 0 end)Œ_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&4~&0~&0~&-1~&2~&-1~&-1~&$#,##0~&$-#,##0~&~&~&~&~&~&NF_~&SIMSTY_~&mtd_s04pG0  MTD Sales vs Prev Yr MTD Sales %}case when sum(case when datepart(yyyy,1.sales_date)=datepart(yyyy,getdate())-1 and datepart(mm,1.sales_date)=datepart(mm,getdate()) and datepart(d,1.sales_date)<=datepart(d,getdate()) then 1.store_sales else 0 end) = 0 then 0 else (sum(case when datepart(yyyy,1.sales_date)=datepart(yyyy,getdate()) and datepart(mm,1.sales_date)=datepart(mm,getdate()) and 1.sales_date<= getdate() then 1.store_sales else 0 end) / sum(case when datepart(yyyy,1.sales_date)=datepart(yyyy,getdate())-1 and datepart(mm,1.sales_date)=datepart(mm,getdate()) and datepart(d,1.sales_date)<=datepart(d,getdate()) then 1.store_sales else 0 end))-1 end†_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&7~&0~&0~&-1~&-1~&-1~&-1~&0.00 %~&~&~&~&~&~&~&NF_~&SIMSTY_~&mtd_s0muG0§Previous Month TD SalesUsum(case when case when datepart(mm,getdate())=1 then 12 else datepart(mm,getdate())-1 end = datepart(mm,1.sales_date) and case when datepart(mm,getdate())=1 then datepart(yyyy,getdate())-1 else datepart(yyyy,getdate()) end = datepart(yyyy,1.sales_date) and datepart(d,1.sales_date)<=datepart(d,getdate()) then 1.store_sales else 0 end)€_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&257~&STY_~&_STYFIELDS~&257~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&0~&0~&0~&-1~&-1~&-1~&-1~&~&~&~&~&~&~&~&NF_~&SIMSTY_~&mtd_s04rG0¨"MTD Sales less Prev Month TD Salessum(case when datepart(yyyy,1.sales_date)=datepart(yyyy,getdate()) and datepart(mm,1.sales_date)=datepart(mm,getdate()) and 1.sales_date<= getdate() then 1.store_sales else 0 end) - sum(case when case when datepart(mm,getdate())=1 then 12 else datepart(mm,getdate())-1 end = datepart(mm,1.sales_date) and case when datepart(mm,getdate())=1 then datepart(yyyy,getdate())-1 else datepart(yyyy,getdate()) end = datepart(yyyy,1.sales_date) and datepart(d,1.sales_date)<=datepart(d,getdate()) then 1.store_sales else 0 end)Œ_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&769~&STY_~&_STYFIELDS~&769~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&4~&0~&0~&-1~&2~&-1~&-1~&$#,##0~&$-#,##0~&~&~&~&~&~&NF_~&SIMSTY_~&mtd_s04sG0""MTD Sales vs Prev Month TD Sales %‡case when sum(case when case when datepart(mm,getdate())=1 then 12 else datepart(mm,getdate())-1 end = datepart(mm,1.sales_date) and case when datepart(mm,getdate())=1 then datepart(yyyy,getdate())-1 else datepart(yyyy,getdate()) end = datepart(yyyy,1.sales_date) and datepart(d,1.sales_date)<=datepart(d,getdate()) then 1.store_sales else 0 end) = 0 then 0 else (sum(case when datepart(yyyy,1.sales_date)=datepart(yyyy,getdate()) and datepart(mm,1.sales_date)=datepart(mm,getdate()) and 1.sales_date<= getdate() then 1.store_sales else 0 end) / sum(case when case when datepart(mm,getdate())=1 then 12 else datepart(mm,getdate())-1 end = datepart(mm,1.sales_date) and case when datepart(mm,getdate())=1 then datepart(yyyy,getdate())-1 else datepart(yyyy,getdate()) end = datepart(yyyy,1.sales_date) and datepart(d,1.sales_date)<=datepart(d,getdate()) then 1.store_sales else 0 end))-1 end†_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&769~&STY_~&_STYFIELDS~&769~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&7~&0~&0~&-1~&-1~&-1~&-1~&0.00 %~&~&~&~&~&~&~&NF_~&SIMSTY_~&mtd_s0mwG0ŚPrevious Month Sales sum(case when case when datepart(mm,getdate())=1 then 12 else datepart(mm,getdate())-1 end = datepart(mm,1.sales_date) and case when datepart(mm,getdate())=1 then datepart(yyyy,getdate())-1 else datepart(yyyy,getdate()) end = datepart(yyyy,1.sales_date) then 1.store_sales else 0 end)†_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&4~&0~&0~&-1~&-1~&-1~&-1~&$#,##0~&~&~&~&~&~&~&NF_~&SIMSTY_~&mtd_s04qG0˝Previous Month Last Year Sales"sum(case when case when datepart(mm,getdate())=1 then 12 else datepart(mm,getdate())-1 end = datepart(mm,1.sales_date) and case when datepart(mm,getdate())=1 then datepart(yyyy,getdate())-2 else datepart(yyyy,getdate())-1 end = datepart(yyyy,1.sales_date) then 1.store_sales else 0 end)†_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&4~&0~&0~&-1~&-1~&-1~&-1~&$#,##0~&~&~&~&~&~&~&NF_~&SIMSTY_~&last_05eG0(12 Month Sales AJanuary(Lsum(case when datepart(mm,1.sales_date) = 1 then 1.store_sales else 0 end)Œ_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&769~&STY_~&_STYFIELDS~&769~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&4~&0~&0~&-1~&2~&-1~&-1~&$#,##0~&$-#,##0~&~&~&~&~&~&NF_~&SIMSTY_~&objec0nsG0BFebruary(Lsum(case when datepart(mm,1.sales_date) = 2 then 1.store_sales else 0 end)Œ_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&769~&STY_~&_STYFIELDS~&769~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&4~&0~&0~&-1~&2~&-1~&-1~&$#,##0~&$-#,##0~&~&~&~&~&~&NF_~&SIMSTY_~&janua0ntG0CMarch(Lsum(case when datepart(mm,1.sales_date) = 3 then 1.store_sales else 0 end)Œ_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&769~&STY_~&_STYFIELDS~&769~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&4~&0~&0~&-1~&2~&-1~&-1~&$#,##0~&$-#,##0~&~&~&~&~&~&NF_~&SIMSTY_~&febru0nuG0DApril(Lsum(case when datepart(mm,1.sales_date) = 4 then 1.store_sales else 0 end)Œ_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&769~&STY_~&_STYFIELDS~&769~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&4~&0~&0~&-1~&2~&-1~&-1~&$#,##0~&$-#,##0~&~&~&~&~&~&NF_~&SIMSTY_~&march0nvG0EMay(Lsum(case when datepart(mm,1.sales_date) = 5 then 1.store_sales else 0 end)Œ_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&769~&STY_~&_STYFIELDS~&769~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&4~&0~&0~&-1~&2~&-1~&-1~&$#,##0~&$-#,##0~&~&~&~&~&~&NF_~&SIMSTY_~&april0nwG0FJune(Lsum(case when datepart(mm,1.sales_date) = 6 then 1.store_sales else 0 end)Œ_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&769~&STY_~&_STYFIELDS~&769~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&4~&0~&0~&-1~&2~&-1~&-1~&$#,##0~&$-#,##0~&~&~&~&~&~&NF_~&SIMSTY_~&may20nxG0GJuly(Lsum(case when datepart(mm,1.sales_date) = 7 then 1.store_sales else 0 end)Œ_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&769~&STY_~&_STYFIELDS~&769~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&4~&0~&0~&-1~&2~&-1~&-1~&$#,##0~&$-#,##0~&~&~&~&~&~&NF_~&SIMSTY_~&june20nyG0HAugust(Lsum(case when datepart(mm,1.sales_date) = 8 then 1.store_sales else 0 end)Œ_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&769~&STY_~&_STYFIELDS~&769~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&4~&0~&0~&-1~&2~&-1~&-1~&$#,##0~&$-#,##0~&~&~&~&~&~&NF_~&SIMSTY_~&july20o0G0I September(Lsum(case when datepart(mm,1.sales_date) = 9 then 1.store_sales else 0 end)Œ_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&769~&STY_~&_STYFIELDS~&769~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&4~&0~&0~&-1~&2~&-1~&-1~&$#,##0~&$-#,##0~&~&~&~&~&~&NF_~&SIMSTY_~&augus0o1G0JOctober(Msum(case when datepart(mm,1.sales_date) = 10 then 1.store_sales else 0 end)Œ_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&769~&STY_~&_STYFIELDS~&769~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&4~&0~&0~&-1~&2~&-1~&-1~&$#,##0~&$-#,##0~&~&~&~&~&~&NF_~&SIMSTY_~&septe0o2G0KNovember(Msum(case when datepart(mm,1.sales_date) = 11 then 1.store_sales else 0 end)Œ_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&769~&STY_~&_STYFIELDS~&769~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&4~&0~&0~&-1~&2~&-1~&-1~&$#,##0~&$-#,##0~&~&~&~&~&~&NF_~&SIMSTY_~&octob0o3G0LDecember(Msum(case when datepart(mm,1.sales_date) = 12 then 1.store_sales else 0 end)Œ_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&769~&STY_~&_STYFIELDS~&769~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&4~&0~&0~&-1~&2~&-1~&-1~&$#,##0~&$-#,##0~&~&~&~&~&~&NF_~&SIMSTY_~&novem0o4G0WeeklyˇWeek to Date Salesˇsum(case when datepart(yyyy,1.sales_date)=datepart(yyyy,getdate()) and datepart(wk,1.sales_date)=datepart(wk,getdate()) and 1.sales_date<= getdate() then 1.store_sales else 0 end)mtd_s058G0ťPrevious Week Sales sum(case when case when datepart(wk,getdate())=1 then 52 else datepart(wk,getdate())-1 end = datepart(wk,1.sales_date) and case when datepart(wk,getdate())=1 then datepart(yyyy,getdate())-1 else datepart(yyyy,getdate()) end = datepart(yyyy,1.sales_date) then 1.store_sales else 0 end)last_05cG0źPrevious Week Last Year Sales"sum(case when case when datepart(wk,getdate())=1 then 52 else datepart(wk,getdate())-1 end = datepart(wk,1.sales_date) and case when datepart(wk,getdate())=1 then datepart(yyyy,getdate())-2 else datepart(yyyy,getdate())-1 end = datepart(yyyy,1.sales_date) then 1.store_sales else 0 end)last_05dG03 7 Days SalesUSunday3Lsum(case when datepart(dw,1.sales_date) = 1 then 1.store_sales else 0 end)Œ_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&769~&STY_~&_STYFIELDS~&769~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&4~&0~&0~&-1~&2~&-1~&-1~&$#,##0~&$-#,##0~&~&~&~&~&~&NF_~&SIMSTY_~&q10odG0VMonday3Lsum(case when datepart(dw,1.sales_date) = 2 then 1.store_sales else 0 end)Œ_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&769~&STY_~&_STYFIELDS~&769~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&4~&0~&0~&-1~&2~&-1~&-1~&$#,##0~&$-#,##0~&~&~&~&~&~&NF_~&SIMSTY_~&sunda0oeG0WTuesday3Lsum(case when datepart(dw,1.sales_date) = 3 then 1.store_sales else 0 end)Œ_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&769~&STY_~&_STYFIELDS~&769~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&4~&0~&0~&-1~&2~&-1~&-1~&$#,##0~&$-#,##0~&~&~&~&~&~&NF_~&SIMSTY_~&monda0ofG0X Wednesday3Lsum(case when datepart(dw,1.sales_date) = 4 then 1.store_sales else 0 end)Œ_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&769~&STY_~&_STYFIELDS~&769~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&4~&0~&0~&-1~&2~&-1~&-1~&$#,##0~&$-#,##0~&~&~&~&~&~&NF_~&SIMSTY_~&tuesd0ogG0YThursday3Lsum(case when datepart(dw,1.sales_date) = 5 then 1.store_sales else 0 end)Œ_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&769~&STY_~&_STYFIELDS~&769~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&4~&0~&0~&-1~&2~&-1~&-1~&$#,##0~&$-#,##0~&~&~&~&~&~&NF_~&SIMSTY_~&wedne0ohG0ZFriday3Lsum(case when datepart(dw,1.sales_date) = 6 then 1.store_sales else 0 end)Œ_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&769~&STY_~&_STYFIELDS~&769~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&4~&0~&0~&-1~&2~&-1~&-1~&$#,##0~&$-#,##0~&~&~&~&~&~&NF_~&SIMSTY_~&thurs0oiG0[Saturday3Lsum(case when datepart(dw,1.sales_date) = 7 then 1.store_sales else 0 end)Œ_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&769~&STY_~&_STYFIELDS~&769~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&4~&0~&0~&-1~&2~&-1~&-1~&$#,##0~&$-#,##0~&~&~&~&~&~&NF_~&SIMSTY_~&frida0ojG0Daily Ŕ Today's Salescsum(case when 1.sales_date=convert (SMALLDATETIME, {fn CURDATE()}) then 1.store_sales else 0 end)week_05hG0ÁYesterday's Salesesum(case when 1.sales_date=convert (SMALLDATETIME, {fn CURDATE()})-1 then 1.store_sales else 0 end)today05iG0Â"Today's Sales less Yesterday SalesËsum(case when 1.sales_date=convert (SMALLDATETIME, {fn CURDATE()}) then 1.store_sales else 0 end) - sum(case when 1.sales_date=convert (SMALLDATETIME, {fn CURDATE()})-1 then 1.store_sales else 0 end)objec05jG0#"Today's Sales vs Yesterday Sales %Scase when sum(case when 1.sales_date=convert (SMALLDATETIME, {fn CURDATE()})-1 then 1.store_sales else 0 end) = 0 then 0 else (sum(case when 1.sales_date=convert (SMALLDATETIME, {fn CURDATE()}) then 1.store_sales else 0 end) / sum(case when 1.sales_date=convert (SMALLDATETIME, {fn CURDATE()})-1 then 1.store_sales else 0 end))-1 end†_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&7~&0~&0~&-1~&-1~&-1~&-1~&0.00 %~&~&~&~&~&~&~&NF_~&SIMSTY_~&today0mxG0ĂSame Day One Week Ago Salesesum(case when 1.sales_date=convert (SMALLDATETIME, {fn CURDATE()})-7 then 1.store_sales else 0 end)today05kG0ÄSame Day Year Ago Salesgsum(case when 1.sales_date=convert (SMALLDATETIME, {fn CURDATE()})-365 then 1.store_sales else 0 end)week_05lG0uLast Days Sales3sum(51.Last_Days_Sales)Œ_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&4~&0~&0~&-1~&2~&-1~&-1~&$#,##0~&$-#,##0~&~&~&~&~&~&NF_~&SIMSTY_~&last_0paG0vPenultimate Days Sales3sum(51.Penultimate_Days_Sales)Œ_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&4~&0~&0~&-1~&2~&-1~&-1~&$#,##0~&$-#,##0~&~&~&~&~&~&NF_~&SIMSTY_~&penul0pbG0wLast Day/Penultimate Day Delta33sum(51.Last_Days_Sales-51.Penultimate_Days_Sales)Œ_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&4~&0~&0~&-1~&2~&-1~&-1~&$#,##0~&$-#,##0~&~&~&~&~&~&NF_~&SIMSTY_~&last_0pcG0#Prompted Periods AgoŮn Months Ago Sales#—sum(case when datediff(m, 1.sales_date,getdate()) <= @Prompt('Months Ago','N',,mono,free) and 1.sales_date<=getdate() then 1.store_sales else 0 end)n_wee067G0Řn Weeks Ago Sales#ƒsum(case when 1.sales_date between getdate()-(@Prompt('Weeks Ago','N',,mono,free)*7) and getdate() then 1.store_sales else 0 end)n_day066G0×n Days Ago Sales#~sum(case when 1.sales_date between getdate()-@Prompt('Days Ago','N',,mono,free) and getdate() then 1.store_sales else 0 end)objec065G05Rolling Averages]Week Ending Date5&38.Week_Ending_Dateweek_0olv"^Average Weekly Sales5)avg(41.Sales)Œ_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&4~&0~&0~&-1~&2~&-1~&-1~&$#,##0~&$-#,##0~&~&~&~&~&~&NF_~&SIMSTY_~&sales0omG2&Prompted Measures3 Measure 1&nGeneric measure which prompts for the specific column to be selected and prompts for the aggregation to apply.Xcase when @Prompt('Measure 1 Rollup','A',{'Sum','Average'},mono,constrained)='Sum' then sum(case when @Prompt('Measure 1','A',{'Sales','Cost','Margin','Units'},mono,constrained)='Sales' then 1.store_sales when @Prompt('Measure 1','A',{'Sales','Cost','Margin','Units'},mono,constrained)='Margin' then 1.store_sales-1.store_cost when @Prompt('Measure 1','A',{'Sales','Cost','Margin','Units'},mono,constrained)='Units' then 1.unit_sales else 1.store_cost end) else Avg(case when @Prompt('Measure 1','A',{'Sales','Cost','Margin','Units'},mono,constrained)='Sales' then 1.store_sales when @Prompt('Measure 1','A',{'Sales','Cost','Margin','Units'},mono,constrained)='Margin' then 1.store_sales-1.store_cost when @Prompt('Measure 1','A',{'Sales','Cost','Margin','Units'},mono,constrained)='Units' then 1.unit_sales else 1.store_cost end) end†_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&4~&0~&0~&-1~&-1~&-1~&-1~&$#,##0~&~&~&~&~&~&~&NF_~&SIMSTY_~&measu0neG04 Measure 2&nGeneric measure which prompts for the specific column to be selected and prompts for the aggregation to apply.Xcase when @Prompt('Measure 2 Rollup','A',{'Sum','Average'},mono,constrained)='Sum' then sum(case when @Prompt('Measure 2','A',{'Sales','Cost','Margin','Units'},mono,constrained)='Sales' then 1.store_sales when @Prompt('Measure 2','A',{'Sales','Cost','Margin','Units'},mono,constrained)='Margin' then 1.store_sales-1.store_cost when @Prompt('Measure 2','A',{'Sales','Cost','Margin','Units'},mono,constrained)='Units' then 1.unit_sales else 1.store_cost end) else Avg(case when @Prompt('Measure 2','A',{'Sales','Cost','Margin','Units'},mono,constrained)='Sales' then 1.store_sales when @Prompt('Measure 2','A',{'Sales','Cost','Margin','Units'},mono,constrained)='Margin' then 1.store_sales-1.store_cost when @Prompt('Measure 2','A',{'Sales','Cost','Margin','Units'},mono,constrained)='Units' then 1.unit_sales else 1.store_cost end) end†_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&4~&0~&0~&-1~&-1~&-1~&-1~&$#,##0~&~&~&~&~&~&~&NF_~&SIMSTY_~&measu0nfG02Sum Measure Prompt Column Only&EGeneric measure which prompts for the specific column to be selected.{sum(case when @Prompt('Measure 1','A',{'Sales','Cost','Margin','Units'},mono,constrained)='Sales' then 1.store_sales when @Prompt('Measure 1','A',{'Sales','Cost','Margin','Units'},mono,constrained)='Margin' then 1.store_sales-1.store_cost when @Prompt('Measure 1','A',{'Sales','Cost','Margin','Units'},mono,constrained)='Units' then 1.unit_sales else 1.store_cost end)†_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&4~&0~&0~&-1~&-1~&-1~&-1~&$#,##0~&~&~&~&~&~&~&NF_~&SIMSTY_~&measu0ndG0/ Prompted Banding of Sales Amount&fPrompts for the 3 bin breaks of the sales amount. Returns 4 bins, using the bin breaks in their names.“case when 1.store_sales < @Prompt('First Value','N',,mono,free) then 'Below '+cast(@Variable('First Value') as char(1)) when 1.store_sales >= @Prompt('First Value','N',,mono,free) and 1.store_sales < @Prompt('Second Value','N',,mono,free) then 'Between '+cast(@Variable('First Value') as char(1))+' and '+cast(@Variable('Second Value') as char(1)) when 1.store_sales >= @Prompt('Second Value','N',,mono,free) and 1.store_sales < @Prompt('Third Value','N',,mono,free) then 'Between '+cast(@Variable('Second Value') as char(1))+' and '+cast(@Variable('Third Value') as char(1)) else 'Greater than '+cast(@Variable('Third Value') as char(1)) Endobjec0naf"5#Prompted Banding of Prompted Amount&0Prompts for measure, aggregation and bin breaks.› case when case when @Prompt('Measure 1','A',{'Sales','Cost','Margin','Units'},mono,constrained)='Sales' then 1.store_sales when @Prompt('Measure 1','A',{'Sales','Cost','Margin','Units'},mono,constrained)='Margin' then 1.store_sales-1.store_cost when @Prompt('Measure 1','A',{'Sales','Cost','Margin','Units'},mono,constrained)='Units' then 1.unit_sales else 1.store_cost end < @Prompt('First Value','N',,mono,free) then 'Below '+cast(@Variable('First Value') as char(1)) when case when @Prompt('Measure 1','A',{'Sales','Cost','Margin','Units'},mono,constrained)='Sales' then 1.store_sales when @Prompt('Measure 1','A',{'Sales','Cost','Margin','Units'},mono,constrained)='Margin' then 1.store_sales-1.store_cost when @Prompt('Measure 1','A',{'Sales','Cost','Margin','Units'},mono,constrained)='Units' then 1.unit_sales else 1.store_cost end >= @Prompt('First Value','N',,mono,free) and case when @Prompt('Measure 1','A',{'Sales','Cost','Margin','Units'},mono,constrained)='Sales' then 1.store_sales when @Prompt('Measure 1','A',{'Sales','Cost','Margin','Units'},mono,constrained)='Margin' then 1.store_sales-1.store_cost when @Prompt('Measure 1','A',{'Sales','Cost','Margin','Units'},mono,constrained)='Units' then 1.unit_sales else 1.store_cost end < @Prompt('Second Value','N',,mono,free) then 'Between '+cast(@Variable('First Value') as char(1))+' and '+cast(@Variable('Second Value') as char(1)) when case when @Prompt('Measure 1','A',{'Sales','Cost','Margin','Units'},mono,constrained)='Sales' then 1.store_sales when @Prompt('Measure 1','A',{'Sales','Cost','Margin','Units'},mono,constrained)='Margin' then 1.store_sales-1.store_cost when @Prompt('Measure 1','A',{'Sales','Cost','Margin','Units'},mono,constrained)='Units' then 1.unit_sales else 1.store_cost end >= @Prompt('Second Value','N',,mono,free) and case when @Prompt('Measure 1','A',{'Sales','Cost','Margin','Units'},mono,constrained)='Sales' then 1.store_sales when @Prompt('Measure 1','A',{'Sales','Cost','Margin','Units'},mono,constrained)='Margin' then 1.store_sales-1.store_cost when @Prompt('Measure 1','A',{'Sales','Cost','Margin','Units'},mono,constrained)='Units' then 1.unit_sales else 1.store_cost end < @Prompt('Third Value','N',,mono,free) then 'Between '+cast(@Variable('Second Value') as char(1))+' and '+cast(@Variable('Third Value') as char(1)) else 'Greater than '+cast(@Variable('Third Value') as char(1)) Endpromp0ngf"7Weekly Comparison&6The 3 objects within are designed to be used together.e Focus Week7DPrompts users for a date. Summarizes sales for the preceding 7 days.ş(sum(case when 1.sales_date between dateadd(dd,-6,@Prompt('Week Ending What Date?','D',,mono,free)) and @Prompt('Week Ending What Date?','D',,mono,free) then 1.store_sales else 0 end))Œ_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&769~&STY_~&_STYFIELDS~&769~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&4~&0~&0~&-1~&2~&-1~&-1~&$#,##0~&$-#,##0~&~&~&~&~&~&NF_~&SIMSTY_~&weekl0otG0f Previous Week7aPrompts users for a date. Summarizes the sales for 1 week immediately preceding the date entered.Ę(sum(case when 1.sales_date between dateadd(dd,-13,@Prompt('Week Ending What Date?','D',,mono,free)) and dateadd(dd,-7,@Prompt('Week Ending What Date?','D',,mono,free)) then 1.store_sales else 0 end))Œ_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&769~&STY_~&_STYFIELDS~&769~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&4~&0~&0~&-1~&2~&-1~&-1~&$#,##0~&$-#,##0~&~&~&~&~&~&NF_~&SIMSTY_~&focus0ouG0c Weekly Delta7ŠPrompts users for a date. Summarizes the difference of sales during the week entered with the sales for the week immediately preceding it.…(sum(case when 1.sales_date between dateadd(dd,-6,@Prompt('Week Ending What Date?','D',,mono,free)) and @Prompt('Week Ending What Date?','D',,mono,free) then 1.store_sales else 0 end))-(sum(case when 1.sales_date between dateadd(dd,-13,@Prompt('Week Ending What Date?','D',,mono,free)) and dateadd(dd,-7,@Prompt('Week Ending What Date?','D',,mono,free)) then 1.store_sales else 0 end))Œ_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&769~&STY_~&_STYFIELDS~&769~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&4~&0~&0~&-1~&2~&-1~&-1~&$#,##0~&$-#,##0~&~&~&~&~&~&NF_~&SIMSTY_~&march0orG08Monthly Comparison&6The 3 objects within are designed to be used together.h Focus Month8IPrompts users for a date. Summarizes sales for the month that date is in.(sum(case when 1.sales_date between DATEADD(mm, DATEDIFF(mm, 0, @Prompt('Month containing this date','D',,mono,free)), 0) and dateadd(dd, - 1, dateadd(m, 1, DATEADD(mm, DATEDIFF(mm, 0, @Prompt('Month containing this date','D',,mono,free)), 0))) then 1.store_sales else 0 end))Œ_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&769~&STY_~&_STYFIELDS~&769~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&4~&0~&0~&-1~&2~&-1~&-1~&$#,##0~&$-#,##0~&~&~&~&~&~&NF_~&SIMSTY_~&weekl0otG0lPrevious Month8uPrompts users for a date. Summarizes sales for the entire month previous to the month that was entered at the prompt.(sum(case when 1.sales_date between dateadd(mm,-1,DATEADD(mm, DATEDIFF(mm,0,@Prompt('Month containing this date','D',,mono,free)), 0)) and dateadd(dd,-1,DATEADD(mm, DATEDIFF(mm, 0, @Prompt('Month containing this date','D',,mono,free)), 0)) then 1.store_sales else 0 end))Œ_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&769~&STY_~&_STYFIELDS~&769~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&4~&0~&0~&-1~&2~&-1~&-1~&$#,##0~&$-#,##0~&~&~&~&~&~&NF_~&SIMSTY_~&focus0p1G0m Monthly Delta8ICalculates the difference between Focus Month and Previous Month Objects.*(sum(case when 1.sales_date between DATEADD(mm, DATEDIFF(mm, 0, @Prompt('Month containing this date','D',,mono,free)), 0) and dateadd(dd, - 1, dateadd(m, 1, DATEADD(mm, DATEDIFF(mm, 0, @Prompt('Month containing this date','D',,mono,free)), 0))) then 1.store_sales else 0 end))-(sum(case when 1.sales_date between dateadd(mm,-1,DATEADD(mm, DATEDIFF(mm,0,@Prompt('Month containing this date','D',,mono,free)), 0)) and dateadd(dd,-1,DATEADD(mm, DATEDIFF(mm, 0, @Prompt('Month containing this date','D',,mono,free)), 0)) then 1.store_sales else 0 end))Œ_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&769~&STY_~&_STYFIELDS~&769~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&4~&0~&0~&-1~&2~&-1~&-1~&$#,##0~&$-#,##0~&~&~&~&~&~&NF_~&SIMSTY_~&focus0p2G0 Baskets5 Basket ID  1.basket_idbaske01iv"ËBasket Set Name 17.namename05sv"ĚBasket Set Last Updated  17.last_modlast_05tv"Number of Baskets  17.recordsrecor0mqv"EWhich Basket Sets? Y17.name in @Prompt('Which Basket Sets?','A','Baskets\Basket Set Name',multi,constrained)6Basket Binning aNumber of Baskets in Bin6/Count(distinct 47.basket_id)baske0opG0bBin6.X'=> '+cast(Floor(46.Lower_Value) as char(2))+' and <='+cast(46.Upper_Value as char(2))objec0oqf";Ratios‰#Prompt Product Department Sales Mix;˝sum(case when 4.product_department in @Prompt('Which Product Departments?','A','Product Hierarchy\Product Department',multi,constrained) then 1.store_sales else 0 end)/sum(1.store_sales)†_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&7~&0~&0~&-1~&-1~&-1~&-1~&0.00 %~&~&~&~&~&~&~&NF_~&SIMSTY_~&objec0puG0TimeçCommon Date Ranges26.Date_Rangedate_06lv":Prompted Time DimensionLGeneric object which prompts for the specific time dimension to be selected.şcase when @Prompt('Select a Time Level','A',{'Year','Year & Quarter','Year & Month','Year & Week','Date'},mono,constrained)='Year' then cast(datepart(yyyy,1.sales_date) as char(4)) when @Prompt('Select a Time Level','A',{'Year','Year & Quarter','Year & Month','Year & Week','Date'},mono,constrained)='Year & Quarter' then cast(datepart(yyyy,1.sales_date) as char(4)) +'-Q'+ cast(datepart(q,1.sales_date) as char(1)) when @Prompt('Select a Time Level','A',{'Year','Year & Quarter','Year & Month','Year & Week','Date'},mono,constrained)='Year & Month' then cast(datepart(yyyy,1.sales_date) as char(4)) + case when datepart(mm,1.sales_date)<10 then '-0'+cast(datepart(mm,1.sales_date) as char(1)) else '-'+cast(datepart(mm,1.sales_date) as char(2)) end when @Prompt('Select a Time Level','A',{'Year','Year & Quarter','Year & Month','Year & Week','Date'},mono,constrained)='Year & Week' then cast(datepart(yyyy,1.sales_date) as char(4)) + case when datepart(wk,1.sales_date)<10 then '-0'+cast(datepart(wk,1.sales_date) as char(1)) else '-'+cast(datepart(wk,1.sales_date) as char(2)) end else cast(datepart(yyyy,1.sales_date) as char(4)) + case when datepart(mm,1.sales_date)<10 then '-0'+cast(datepart(mm,1.sales_date) as char(1)) else '-'+cast(datepart(mm,1.sales_date) as char(2)) end + case when datepart(d,1.sales_date)<10 then '-0'+cast(datepart(d,1.sales_date) as char(1)) else '-'+cast(datepart(d,1.sales_date) as char(2)) end end†_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&4~&0~&0~&-1~&-1~&-1~&-1~&$#,##0~&~&~&~&~&~&~&NF_~&SIMSTY_~&promp0nlf"ÚWeek Day/Week EndQcase when datepart(dw,1.sales_date) in (1,7) then 'Week End' else 'Week Day' endobjec068f"4Which Date Ranges?_26.Date_Range in @Prompt('Which Date Ranges?','A','Time\Common Date Ranges',multi,constrained),Year–Year,The Year-cast(datepart(yyyy,1.sales_date) as char(4))_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&3~&0~&0~&-1~&-1~&-1~&-1~&0~&~&~&~&~&~&~&NF_~&SIMSTY_~&sales04af"ŠMax Year,$The Latest Year. This is an integer.!max(datepart(yyyy,1.sales_date))_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&3~&0~&0~&-1~&-1~&-1~&-1~&0~&~&~&~&~&~&~&NF_~&SIMSTY_~&year20pvg ! Year to Date,Sdatepart(yyyy,1.sales_date)=datepart(yyyy,getdate()) and 1.sales_date<= getdate()Last Year to Date,ndatepart(yyyy,1.sales_date)=datepart(yyyy,getdate())-1 and datepart(dy,1.sales_date)<=datepart(dy,getdate())#Prompt Sales Year,Ydatepart(yyyy,1.sales_date)=@Prompt('Transaction Year','N','Year\Year',mono,constrained)-Quarter˜Year & Quarter-Year and Quarter`cast(datepart(yyyy,1.sales_date) as char(4)) +'-Q'+ cast(datepart(q,1.sales_date) as char(1)) sales04cf" Current Quarter to Date-‡datepart(yyyy,1.sales_date)=datepart(yyyy,getdate()) and datepart(q,1.sales_date)=datepart(q,getdate()) and 1.sales_date<= getdate() Last Quarter to Date-"case when datepart(q,getdate())=1 then 4 else datepart(q,getdate())-1 end = datepart(q,1.sales_date) and case when datepart(q,getdate())=1 then datepart(yyyy,getdate())-1 else datepart(yyyy,getdate()) end = datepart(yyyy,1.sales_date) and datepart(d,1.sales_date)<=datepart(d,getdate()) Last Quarter-ícase when datepart(q,getdate())=1 then 4 else datepart(q,getdate())-1 end = datepart(q,1.sales_date) and case when datepart(q,getdate())=1 then datepart(yyyy,getdate())-1 else datepart(yyyy,getdate()) end = datepart(yyyy,1.sales_date)Quarter for Data Point Drilling-Ľdatepart(yyyy,1.sales_date)=datepart(yyyy,@Prompt('CURRENT_DATE','D',,mono,free)) and datepart(q,1.sales_date) = datepart(q,@Prompt('CURRENT_DATE','D',,mono,free)).Month— Year & Month.Ćcast(datepart(yyyy,1.sales_date) as char(4)) + case when datepart(mm,1.sales_date)<10 then '-0'+cast(datepart(mm,1.sales_date) as char(1)) else '-'+cast(datepart(mm,1.sales_date) as char(2)) endsales04bf"ŸYear Month Integer.Îcast(cast(datepart(yyyy,1.sales_date) as char(4)) + case when datepart(mm,1.sales_date)<10 then '0'+cast(datepart(mm,1.sales_date) as char(1)) else+cast(datepart(mm,1.sales_date) as char(2)) end as int)0qhf"¤ Month Name.BShows month number and month name with proper sorting capabilities˛case when datepart(mm,1.sales_date)<10 then '0'+cast(datepart(mm,1.sales_date) as char(1)) else cast(datepart(mm,1.sales_date) as char(2)) end + '-'+datename(mm,1.sales_date)_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&3~&0~&0~&-1~&-1~&-1~&-1~&0~&~&~&~&~&~&~&NF_~&SIMSTY_~&day_o04of" Month to Date.‰datepart(yyyy,1.sales_date)=datepart(yyyy,getdate()) and datepart(mm,1.sales_date)=datepart(mm,getdate()) and 1.sales_date<= getdate()Last Year Month to Date.˘datepart(yyyy,1.sales_date)=datepart(yyyy,getdate())-1 and datepart(mm,1.sales_date)=datepart(mm,getdate()) and datepart(d,1.sales_date)<=datepart(d,getdate())I Current Month This Year and Last.Śdatepart(m,1.sales_date)=datepart(m,getdate()) and (datepart(yyyy,1.sales_date)=datepart(yyyy,getdate()) or datepart(yyyy,1.sales_date)=datepart(yyyy,getdate())-1) Last Month.ňcase when datepart(mm,getdate())=1 then 12 else datepart(mm,getdate())-1 end = datepart(mm,1.sales_date) and case when datepart(mm,getdate())=1 then datepart(yyyy,getdate())-1 else datepart(yyyy,getdate()) end = datepart(yyyy,1.sales_date)Last Month to Date.'case when datepart(mm,getdate())=1 then 12 else datepart(mm,getdate())-1 end = datepart(mm,1.sales_date) and case when datepart(mm,getdate())=1 then datepart(yyyy,getdate())-1 else datepart(yyyy,getdate()) end = datepart(yyyy,1.sales_date) and datepart(d,1.sales_date)<=datepart(d,getdate())Month for Data Point Drilling.§datepart(yyyy,1.sales_date)=datepart(yyyy,@Prompt('CURRENT_DATE','D',,mono,free)) and datepart(mm,1.sales_date) = datepart(mm,@Prompt('CURRENT_DATE','D',,mono,free))\Within the Month.RReceives any date as input and finds all sales activity for the month of that date”1.sales_date between @Prompt('T','D',,mono,free) and dateadd(dd, - 1, dateadd(m, 1, DATEADD(mm, DATEDIFF(mm, 0, @Prompt('T','D',,mono,free)), 0))) /Weekż Year & Week/Ćcast(datepart(yyyy,1.sales_date) as char(4)) + case when datepart(wk,1.sales_date)<10 then '-0'+cast(datepart(wk,1.sales_date) as char(1)) else '-'+cast(datepart(wk,1.sales_date) as char(2)) endyear_05gf"­ Week of Year/datepart(wk,1.sales_date)_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&3~&0~&0~&-1~&-1~&-1~&-1~&0~&~&~&~&~&~&~&NF_~&SIMSTY_~&day_o04xf"ŽWeek of Quarter/C(datepart(wk,1.sales_date)-1)+1-(13*(datepart(q,1.sales_date)-1))objec04yf"? Week of Month/(datepart(d,1.sales_date)/7)+1_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&3~&0~&0~&-1~&-1~&-1~&-1~&0~&~&~&~&~&~&~&NF_~&SIMSTY_~&day_o0nqf" Current Week to Date/‰datepart(yyyy,1.sales_date)=datepart(yyyy,getdate()) and datepart(wk,1.sales_date)=datepart(wk,getdate()) and 1.sales_date<= getdate() Last Week/ňcase when datepart(wk,getdate())=1 then 52 else datepart(wk,getdate())-1 end = datepart(wk,1.sales_date) and case when datepart(wk,getdate())=1 then datepart(yyyy,getdate())-1 else datepart(yyyy,getdate()) end = datepart(yyyy,1.sales_date)Last Week to Date/'case when datepart(wk,getdate())=1 then 52 else datepart(wk,getdate())-1 end = datepart(mm,1.sales_date) and case when datepart(wk,getdate())=1 then datepart(yyyy,getdate())-1 else datepart(yyyy,getdate()) end = datepart(yyyy,1.sales_date) and datepart(d,1.sales_date)<=datepart(d,getdate()) Last 7 Days/k1.sales_date between convert (SMALLDATETIME, {fn CURDATE()})-7 and convert (SMALLDATETIME, {fn CURDATE()})Week for Data Point Drilling/§datepart(yyyy,1.sales_date)=datepart(yyyy,@Prompt('CURRENT_DATE','D',,mono,free)) and datepart(wk,1.sales_date) = datepart(wk,@Prompt('CURRENT_DATE','D',,mono,free))0DayęDate0 1.sales_dateobjec06ov"4 Sales Date0\cast(datepart(yyyy,1.sales_date) as char(4)) + case when datepart(mm,1.sales_date)<10 then '-0'+cast(datepart(mm,1.sales_date) as char(1)) else '-'+cast(datepart(mm,1.sales_date) as char(2)) end + case when datepart(d,1.sales_date)<10 then '-0'+cast(datepart(d,1.sales_date) as char(1)) else '-'+cast(datepart(d,1.sales_date) as char(2)) endŠ_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&5~&0~&0~&-1~&-1~&-1~&-1~&mm/dd/yyyy~&~&~&~&~&~&~&NF_~&SIMSTY_~&sales01hf"ˆSales Date Only0nconvert(datetime,cast(datepart(yyyy,1.sales_date) as char(4)) + case when datepart(mm,1.sales_date)<10 then '-0'+cast(datepart(mm,1.sales_date) as char(1)) else '-'+cast(datepart(mm,1.sales_date) as char(2)) end + case when datepart(d,1.sales_date)<10 then '-0'+cast(datepart(d,1.sales_date) as char(1)) else '-'+cast(datepart(d,1.sales_date) as char(2)) end)Š_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&5~&0~&0~&-1~&-1~&-1~&-1~&mm/dd/yyyy~&~&~&~&~&~&~&NF_~&SIMSTY_~&sales0ptf"ÖFirst Date of Month0.DATEADD(mm, DATEDIFF(mm, 0, 1.sales_date), 0)objec064f"+Last Date of the Month0Pdateadd(dd, - 1, dateadd(m, 1, DATEADD(mm, DATEDIFF(mm, 0, 1.sales_date), 0))) date20n6f"(First Date Previous Month0;dateadd(mm,-1,DATEADD(mm, DATEDIFF(mm,0,1.sales_date), 0))date20n3f"'Last Date Previous Month0=dateadd(dd,-1,DATEADD(mm, DATEDIFF(mm, 0, 1.sales_date), 0))date20n2f")First Date Previous Quarter0=dateadd(qq,-1,DATEADD(qq, DATEDIFF(qq,0,1.sales_date), 0)) date20n4f"*Last Date Previous Quarter0:dateadd(d,-1,DATEADD(qq, DATEDIFF(qq,0,1.sales_date), 0))date20n5f"„First Date of Quarter0,DATEADD(qq, DATEDIFF(qq,0,1.sales_date), 0)objec0ppf"ƒLast Date of Quarter0/DATEADD(qq, DATEDIFF(qq,-1,1.sales_date), 0)-1objec0pof"‡First Date of the Year0,DATEADD(yy, DATEDIFF(yy,0,1.sales_date), 0)objec0psf"†Last Date of the Year0?dateadd(ms,-3,DATEADD(yy, DATEDIFF(yy,0,1.sales_date )+1, 0))objec0prf" First Date of Previous Year0;dateadd(yy,-1,DATEADD(yy, DATEDIFF(yy,0,1.sales_date), 0))0qif"S Maximum Date0max(1.sales_date)objec0obg !ä Minimum Date0min(1.sales_date)Š_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&5~&0~&0~&-1~&-1~&-1~&-1~&mm/dd/yyyy~&~&~&~&~&~&~&NF_~&SIMSTY_~&sales06ig ŇWeek Ending Date0/(1.sales_date - DATEPART(dw, 1.sales_date))+7objec060f",Week Beginning Airline Date0/(1.sales_date - DATEPART(dw, 1.sales_date))+2week_0n7f"o#Day of Month, Month and Day of Week0case when datepart(d,Current_Facts.sales_date)<10 then '0'+cast(datepart(d,Current_Facts.sales_date) as char(1)) else cast(datepart(d,Current_Facts.sales_date) as char(2)) end+' '+left(datename(m,Current_Facts.sales_date),3)+' '+left(datename(dw,1.sales_date),3)date20p4f"Today051.sales_date=convert (SMALLDATETIME, {fn CURDATE()}) Yesterday071.sales_date=convert (SMALLDATETIME, {fn CURDATE()})-1KLast Day0Last DayQ1.sales_date = (select max(dbo.Current_Facts.sales_date) from dbo.Current_Facts)JPenultimate Day07The second to last day in a series of transaction datesĚ1.sales_date = (select min(Last_Two_Dates.Last_Two_Dates) from (select distinct top 2 Current_Facts.sales_date as Last_Two_Dates from Current_Facts order by Current_Facts.sales_date desc) Last_Two_Dates)Same Day Last Week071.sales_date=convert (SMALLDATETIME, {fn CURDATE()})-7 Last 30 Days0l1.sales_date between convert (SMALLDATETIME, {fn CURDATE()})-30 and convert (SMALLDATETIME, {fn CURDATE()}) Week Days0(datepart(dw,1.sales_date) not in (1,7)  Week Ends0$datepart(dw,1.sales_date) in (1,7) 1Relative Day of Period0œ Day of Year1datepart(dy,1.sales_date)_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&3~&0~&0~&-1~&-1~&-1~&-1~&0~&~&~&~&~&~&~&NF_~&SIMSTY_~&sales04gf"ŻDay of Quarter1case when datepart(q,1.sales_date) = 2 then (datepart(dy,1.sales_date))-(90*(datepart(q,1.sales_date)-1)) when datepart(q,1.sales_date) = 3 then (datepart(dy,1.sales_date))-(90*(datepart(q,1.sales_date)-1)) else (datepart(dy,1.sales_date))-(91*(datepart(q,1.sales_date)-1)) endweek_050f" Day of Month1datepart(d,1.sales_date)_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&3~&0~&0~&-1~&-1~&-1~&-1~&0~&~&~&~&~&~&~&NF_~&SIMSTY_~&day_o04hf"ž Day of Week1Icast(datepart(dw,1.sales_date) as char(1))+'-'+datename(w,1.sales_date)Š_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&5~&0~&0~&-1~&-1~&-1~&-1~&mm/dd/yyyy~&~&~&~&~&~&~&NF_~&SIMSTY_~&day_o04if"-Day of Week Airline1‡case when datepart(dw,1.sales_date)=1 then '7-' else cast(datepart(dw,1.sales_date)-1 as char(1)) end +'-'+datename(dw,1.sales_date)Š_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&5~&0~&0~&-1~&-1~&-1~&-1~&mm/dd/yyyy~&~&~&~&~&~&~&NF_~&SIMSTY_~&day_o0n8f""Relative Time AgoĐDays Ago"$datediff(d,1.sales_date, getdate())…_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&3~&0~&0~&-1~&-1~&-1~&-1~&#,##0~&~&~&~&~&~&~&NF_~&SIMSTY_~&objec05xf"Ń Weeks Ago"%datediff(wk,1.sales_date, getdate())…_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&3~&0~&0~&-1~&-1~&-1~&-1~&#,##0~&~&~&~&~&~&~&NF_~&SIMSTY_~&days_05yf"Ó Months Ago"$datediff(m,1.sales_date, getdate())…_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&3~&0~&0~&-1~&-1~&-1~&-1~&#,##0~&~&~&~&~&~&~&NF_~&SIMSTY_~&weeks061f"Ô Quarters Ago"$datediff(q,1.sales_date, getdate())…_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&3~&0~&0~&-1~&-1~&-1~&-1~&#,##0~&~&~&~&~&~&~&NF_~&SIMSTY_~&month062f"Ő Years Ago"'datediff(yyyy,1.sales_date, getdate())…_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&3~&0~&0~&-1~&-1~&-1~&-1~&#,##0~&~&~&~&~&~&~&NF_~&SIMSTY_~&quart063f"Last n Days Ago",Prompts user for number of days ago to fetchP1.sales_date between getdate()-@Prompt('Days Ago','N',,mono,free) and getdate()Last n Weeks Ago"-Prompts user for number of weeks ago to fetchU1.sales_date between getdate()-(@Prompt('Weeks Ago','N',,mono,free)*7) and getdate()Last n Months Ago".Prompts user for number of months ago to fetchidatediff(m, 1.sales_date,getdate()) <= @Prompt('Months Ago','N',,mono,free) and 1.sales_date<=getdate()WLast n Months Ago Ending When">Prompts user for number of months ago from a prompted end dateĄdatediff(m, 1.sales_date,@Prompt('Ending Date','D',,mono,free)) <= @Prompt('Months Ago','N',,mono,free) and 1.sales_date<=@Prompt('Ending Date','D',,mono,free)LLast n Days Ago with activity"QPrompts user for the number of days ago of activity. Skips days with no activity.÷1.sales_date >= (select min(Last_N_Dates.Last_N_Dates) from (select distinct top @Prompt('How many days of activity','N',,mono,free) Current_Facts.sales_date as Last_N_Dates from Current_Facts order by Current_Facts.sales_date desc) Last_N_Dates) CustomerGOne Random Customer &2.customer_id = floor((10281*rand()))HTen Random Customers 149.Customer_ID=2.customer_idSTop & Bottom N Customers :Returns the Top N Top and Bottom Customers, based on SalesÓ1.customer_id in (SELECT top @Prompt('How Many Customers?','N',,mono,free) dbo.Current_Facts.customer_id FROM dbo.Current_Facts GROUP BY dbo.Current_Facts.customer_id ORDER BY sum(dbo.Current_Facts.store_sales) DESC ) OR 1.customer_id in (SELECT top @Prompt('How Many Customers?','N',,mono,free) dbo.Current_Facts.customer_id FROM dbo.Current_Facts GROUP BY dbo.Current_Facts.customer_id ORDER BY sum(dbo.Current_Facts.store_sales) ASC ), Top n Customers - Lifetime Sales $Prompts user for number of customers2.customer_id in (select top @Prompt('No. of Customers','N',,mono,free) customer_id from lifetime_customer_value order by lifetime_sales desc).!Top n Customers-Current Qtr Sales $Prompts user for number of customers2.customer_id in (select top @Prompt('No. of Customers','N',,mono,free) customer_id from quarterly_customer_facts where quarter_begin_date = ( SELECT MAX(quarter_Begin_Date) FROM quarterly_Customer_Facts WHERE quarter_Begin_Date <= GETDATE()) order by store_sales desc)-#Top n Customers-Current Month Sales $Prompts user for number of customers2.customer_id in (select top @Prompt('No. of Customers','N',,mono,free) customer_id from monthly_customer_facts where month_begin_date = ( SELECT MAX(Month_Begin_Date) FROM Monthly_Customer_Facts WHERE Month_Begin_Date <= GETDATE()) order by store_sales desc)/"Top n Customers-Current Week Sales $Prompts user for number of customers2.customer_id in (select top @Prompt('No. of Customers','N',,mono,free) customer_id from weekly_customer_facts where week_ending_date = ( SELECT MAX(week_ending_Date) FROM weekly_Customer_Facts WHERE week_ending_Date <= GETDATE()) order by store_sales desc):Top n Customers-n Quarters Ago _Prompts user for number of customers and and the number of periods ago to evaluate the ranking.92.customer_id in (select top @Prompt('No. of Customers','N',,mono,free) customer_id from quarterly_customer_facts where datediff(q, quarter_begin_date,getdate()) = @Prompt('Quarters Ago','N',,mono,free) order by store_sales desc) and datediff(q,1.sales_date, getdate()) = @Prompt('Quarters Ago','N',,mono,free) 6Top n Customers-n Months Ago _Prompts user for number of customers and and the number of periods ago to evaluate the ranking.12.customer_id in (select top @Prompt('No. of Customers','N',,mono,free) customer_id from monthly_customer_facts where datediff(m, month_begin_date,getdate()) = @Prompt('Months Ago','N',,mono,free) order by store_sales desc) and datediff(m,1.sales_date, getdate()) = @Prompt('Months Ago','N',,mono,free) 9Top n Customers-n Weeks Ago _Prompts user for number of customers and and the number of periods ago to evaluate the ranking.02.customer_id in (select top @Prompt('No. of Customers','N',,mono,free) customer_id from weekly_customer_facts where datediff(wk, week_ending_date,getdate()) = @Prompt('Weeks Ago','N',,mono,free) order by store_sales desc) and datediff(wk,1.sales_date, getdate()) = @Prompt('Weeks Ago','N',,mono,free) Current Year Customers Đ1.customer_id in (select distinct dbo.Current_Facts.customer_id from dbo.Current_Facts where datepart(yyyy,dbo.Current_Facts.sales_date)=datepart(yyyy,getdate()) and dbo.Current_Facts.sales_date<= getdate())Previous Year Customers Ľ1.customer_id in (select distinct dbo.Current_Facts.customer_id from dbo.Current_Facts where datepart(yyyy,dbo.Current_Facts.sales_date)=datepart(yyyy,getdate())-1)!Prompt 1st Purchase Year Í2.customer_id in (select distinct dbo.Current_Facts.customer_id from dbo.Current_Facts where datepart(yyyy,dbo.Current_Facts.sales_date)=@Prompt('Initial Purchase Year','N','Year\Year',mono,constrained) )"Prompt 2nd Purchase Year Ě2.customer_id in (select distinct dbo.Current_Facts.customer_id from dbo.Current_Facts where datepart(yyyy,dbo.Current_Facts.sales_date)=@Prompt('Second Purchase Year','N','Year\Year',mono,constrained) ) Demographic PMarital StatusBcase when 2.marital_status = 'M' then 'Married' else 'Single' endmarit02af"Q Yearly Income2.yearly_incomeyearl02bv"RGender7case when 2.gender = 'M' then 'Male' else 'Female' endgende02cf"STotal Number of Children2.total_childrentotal02dv"TNumber of Children at Home2.num_children_at_homenum_c02ev"UEducation Level 2.educationeduca02fv"X Occupation 2.occupationoccup02iv"Y Homeowner@case when 2.houseowner = 'Y' then 'Homeowner' else 'Renter' endhouse02jf"ZNumber of Cars Owned2.num_cars_ownednum_c02kv"Account ? Customer ID2.customer_idcusto01sv"@Account Number2.account_numaccou01tv"W Member Card2.member_cardmembe02hv"VDate Acct opened2.date_accnt_openeddate_02gv" Geographic KCountry 2.countrycount025v"IState Province2.state_provincestate023v"HCity2.citycity022v"J Postal Code2.postal_codeposta024v"DAddress1 2.address1addre01xv"EAddress2 2.address2addre01yv"FAddress3 2.address3addre020v"GAddress4 2.address4addre021v"Personal Ź Customer Name2.lname + ', '+2.fnameobjec04wf"A Last Name2.lnamelname01uv"B First Name2.fnamefname01vv"CMiddle Initial2.mimi01wv"O Birthdate 2.birthdatebirth029v"Ş Customer Age%datediff(yyyy,2.birthdate,getdate())objec04uf"MPhone1 2.phone1phone027v"NPhone2 2.phone2phone028v"Customer Segments ÇCustomer Set Name 13.namename05ov"ĄPredictive Set NameD68.name0qjv"ČCustomer Set Last Updated 13.last_modlast_05pv"ŕCustomer Score 14.points_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&3~&0~&0~&-1~&-1~&-1~&-1~&0~&~&~&~&~&~&~&NF_~&SIMSTY_~&point06ev"íNumber of Customers in Set 13.recordsrecor06rV2áAverage Customer Scoreavg(cast(14.points as float))point06fG0DWhich Customer Sets? g13.name in @Prompt('Which Customer Sets?','A','Customer Segments\Customer Set Name',multi,constrained)(Current Members%14.edate = '2999-12-31 00:00:00.000' Product XWhat Product Families? Ő@Prompt('Product','A',{'All Products','Food','Drink','Non-Consumable'},mono,constrained)=4.product_family or @Prompt('Product','A',{'All Products','Food','Drink','Non-Consumable'},mono,constrained)='All Products'[Which Product Department? 7Prompts user to enter a department or 'All Departments'„@Prompt('Product Department','A',,mono,free)=4.product_department or @Prompt('Product Department','A',,mono,free)='All Departments'UTop & Bottom N Products AReturns the Top N Top and Bottom Products based on Lifetime Sales=3.SKU in (SELECT Top @Prompt('How Many Products?','N',,mono,free) dbo.product.SKU FROM dbo.Current_Facts, dbo.product WHERE ( dbo.Current_Facts.product_id=dbo.product.product_id ) GROUP BY dbo.product.SKU ORDER BY sum(dbo.Current_Facts.store_sales) DESC) or 3.SKU in (SELECT Top @Prompt('How Many Products?','N',,mono,free) dbo.product.SKU FROM dbo.Current_Facts, dbo.product WHERE ( dbo.Current_Facts.product_id=dbo.product.product_id ) GROUP BY dbo.product.SKU ORDER BY sum(dbo.Current_Facts.store_sales) ASC)2 Product not sold in current year Ô3.product_id not in (select distinct dbo.Current_Facts.product_id from dbo.Current_Facts where datepart(yyyy,dbo.Current_Facts.sales_date) = datepart(yyyy,getdate()) and dbo.Current_Facts.sales_date<= getdate())0!Product not sold in current month 3.product_id not in (select distinct dbo.Current_Facts.product_id from dbo.Current_Facts where datepart(yyyy,dbo.Current_Facts.sales_date) = datepart(yyyy,getdate()) and datepart(m,dbo.Current_Facts.sales_date) = datepart(m,getdate()) and dbo.Current_Facts.sales_date<= getdate())1 Product not sold in current week 3.product_id not in (select distinct dbo.Current_Facts.product_id from dbo.Current_Facts where datepart(yyyy,dbo.Current_Facts.sales_date) = datepart(yyyy,getdate()) and datepart(wk,dbo.Current_Facts.sales_date) = datepart(wk,getdate()) and dbo.Current_Facts.sales_date<= getdate())5!Top n Product-Current Month Sales #Prompts user for number of products˙3.product_id in (select top @Prompt('No. of Products','N',,mono,free) product_id from monthly_product_facts where month_begin_date = ( SELECT MAX(Month_Begin_Date) FROM Monthly_Product_Facts WHERE Month_Begin_Date <= GETDATE()) order by store_sales desc)7Top n Products-n Months Ago ^Prompts user for number of products and and the number of periods ago to evaluate the ranking.-3.product_id in (select top @Prompt('No. of Products','N',,mono,free) product_id from monthly_product_facts where datediff(m, month_begin_date,getdate()) = @Prompt('Months Ago','N',,mono,free) order by store_sales desc) and datediff(m,1.sales_date, getdate()) = @Prompt('Months Ago','N',,mono,free) 8Bottom n Products-n Months Ago ‡Prompts user for number of products and and the number of periods ago to evaluate the ranking. Includes only those products with sales.(3.product_id in (select top @Prompt('No. of Products','N',,mono,free) product_id from monthly_product_facts where datediff(m, month_begin_date,getdate()) = @Prompt('Months Ago','N',,mono,free) order by store_sales) and datediff(m,1.sales_date, getdate()) = @Prompt('Months Ago','N',,mono,free) FTop 5 Products CSelects Top 5 products at a Store when logged on as a Store Manager,1.product_id=44.Product_IDM!Top N Products for Top N Customer gPrompts user for number of products, for the number of customers for a number of days of sales history.45’1.customer_id=52.customer_id and 1.product_id = 53.product_id and datediff(d,1.sales_date,getdate())<=@Prompt('How Many Days','N',,mono,free)^Which Products? 8Prompts user to enter a Product Family or 'All Products'[@Prompt('P','A',,mono,free)=4.product_family or @Prompt('P','A',,mono,free)='All Products' Product Hierarchy nProduct Family 4.product_familyprodu035v"mProduct Department 4.product_departmentprodu034v"lProduct Category 4.product_categoryprodu033v"kProduct Subcategory 4.product_subcategoryprodu032v"™Generic Product Name Xsubstring(3.product_name, len(3.brand_name)+2,len(3.product_name)-len(3.brand_name))objec04df"_SKU 3.SKUsku02pv"`Standard Retail Price 3.SRPsrp02qv"9Prompted Product Dimension OGeneric object which prompts for the specific product dimension to be selected.›case when @Prompt('Select a Product Level','A',{'Product Family','Product Department','Product Category','Product Subcategory','Product Name'},mono,constrained)='Product Family' then 4.product_family when @Prompt('Select a Product Level','A',{'Product Family','Product Department','Product Category','Product Subcategory','Product Name'},mono,constrained)='Product Department' then 4.product_department when @Prompt('Select a Product Level','A',{'Product Family','Product Department','Product Category','Product Subcategory','Product Name'},mono,constrained)='Product Category' then 4.product_category when @Prompt('Select a Product Level','A',{'Product Family','Product Department','Product Category','Product Subcategory','Product Name'},mono,constrained)='Product Subcategory' then 4.product_subcategory else substring(3.product_name, len(3.brand_name)+2,len(3.product_name)-len(3.brand_name)) end†_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&4~&0~&0~&-1~&-1~&-1~&-1~&$#,##0~&~&~&~&~&~&~&NF_~&SIMSTY_~&sum_m0nkf"˘ All Products 'All Products'0qkf"Physical Attributes ’ Product ID 3.product_idprodu0q4v"a Gross Weight3.gross_weightgross02rv"b Net Weight 3.net_weightnet_w02sv"cRecyclable Package3.recyclable_packagerecyc02tv"dLow Fat 3.low_fatlow_f02uv"eUnits Per Case3.units_per_caseunits02vv"fCases Per Pallet3.cases_per_palletcases02wv"g Shelf Width3.shelf_widthshelf02xv"h Shelf Height3.shelf_heightshelf02yv"i Shelf Depth3.shelf_depthshelf030v"Brand ] Brand Name 3.brand_namebrand02nv"^Branded Product Name3.product_nameprodu02ov"; What Brands?Ç3.brand_name IN @Prompt('What Brands? (type all for all values)','A','Brand\Brand Name',multi,free) or 'all' in @Prompt('What Brands? (type all for all values)','A','Brand\Brand Name',multi,free)  Product Sets ÉProduct Set Name15.namename05qv"ĘProduct Set Last Updated 15.last_modlast_05rv"îNumber of Products in Set 15.records…_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&3~&0~&0~&-1~&-1~&-1~&-1~&#,##0~&~&~&~&~&~&~&NF_~&SIMSTY_~&recor06sV23Which Product Sets?`15.name in @Prompt('Which Product Sets?','A','Product Sets\Product Set Name',multi,constrained)Store€ Store Name 6.store_citystore03nv"‡ Store Manager6.store_managerstore03uv"_ Status For&The name of the user that is logged onacase when @Variable('BOUSER')=6.store_manager THEN 6.store_manager ELSE @Variable('BOUSER') endobjec0onf"~ Store Type 6.store_typestore03lv" Store Number6.store_numberstore03ov"]Which Countries?JPrompts user to enter a Country Name (USA, Mexico, Canada) or 'All Stores'X@Prompt('S','A',,mono,free)=6.store_country or @Prompt('S','A',,mono,free)='All Stores'Z Which Store?-Prompts user to enter a store or 'All Stores'g@Prompt('Store Name','A',,mono,free)=6.store_city or @Prompt('Store Name','A',,mono,free)='All Stores'Location Details † Store Country6.store_countrystore03tv"„ Store State6.store_statestore03rv"ƒ Store City 6.store_citystore03qv"‚Store Street Address6.store_street_addressstore03pv"…Store Postal Code6.store_postal_codestore03sv"ˆ Store Phone6.store_phonestore03vv"‰ Store Fax 6.store_faxstore03wv"“Store ID 6.store_idstore0q5v"Ł All Stores 'All Stores'0qlf"YWhat Countries?Ç@Prompt('Country','A',{'All Countries','Canada','Mexico','USA'},mono,constrained)=6.store_country or @Prompt('Country','A',{'All Countries','Canada','Mexico','USA'},mono,constrained)='All Countries'Store Physical Attributes&Total Store Sq Ftsum(6.store_sqft)store0n1G0Œ Lease Sqft 6.lease_sqftlease040v" Store Sqft 6.store_sqftstore041v"Ž Grocery Sqft6.grocery_sqftgroce042v" Frozen Sqft6.frozen_sqftfroze043v" Meat Sqft 6.meat_sqftmeat_044v"‘ Coffee Bar 6.coffee_barcoffe045v"’ Video Store6.video_storevideo046v"“ Salad Bar 6.salad_barsalad047v"” Prepared Food6.prepared_foodprepa048v"•Florist 6.floristflori049v"ŠFirst Opened Date6.first_opened_datefirst03xv"‹Last Remodel Date6.last_remodel_datelast_03yv"Š Store Age-datediff(yyyy,6.first_opened_date,getdate())objec04tf" PromotionqPromotion Name 5.promotion_namepromo038v"r Media Type  5.media_typemedia039v"sCost  sum(5.cost)Œ_FIXSETTING~&_SIMSTY~&_STY~&_RPTCOL~&1~&65280~&65280~&65280~&RPTCOL_~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&Arial ~&12~&0~&0~&0~&0~&_RPTCOL~&1~&0~&0~&0~&RPTCOL_~&0~&0~&513~&STY_~&_STYFIELDS~&513~&0~&STYFIELDS_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_BOR~&1~&0~&1~&0~&0~&0~&BOR_~&_NF~&4~&0~&0~&-1~&2~&-1~&-1~&$#,##0~&$-#,##0~&~&~&~&~&~&NF_~&SIMSTY_~&cost03aG0o Promotion ID 5.promotion_idpromo036v"PK r2<űäƒĚŒŒColumns; product_id customer_id promotion_idstore_id sales_date basket_idLast_Days_SalesPenultimate_Days_Sales customer_id Store_Sales product_id customer_id promotion_idstore_id store_sales store_cost unit_sales sales_date basket_id store_margin product_id Store_Sales customer_id account_numlnamefnamemiaddress1address2address3address4citystate_province postal_codecountrycustomer_region_idphone1phone2 birthdatemarital_status yearly_incomegendertotal_childrennum_children_at_home educationdate_accnt_opened member_card occupation houseownernum_cars_ownedproduct_class_id product_id brand_name product_nameSKUSRP gross_weight net_weightrecyclable_packagelow_fatunits_per_casecases_per_pallet shelf_width shelf_height shelf_depth Begin_DateWeek_Ending_Dateproduct_class_idproduct_subcategoryproduct_categoryproduct_departmentproduct_family promotion_idpromotion_district_idpromotion_name media_typecost start_dateend_datestore_id store_type region_id store_name store_numberstore_street_address store_city store_statestore_postal_code store_country store_manager store_phone store_faxfirst_opened_datelast_remodel_date lease_sqft store_sqft grocery_sqft frozen_sqft meat_sqft coffee_bar video_store salad_bar prepared_foodfloristWeek_Ending_DateSalesWeek_Ending_DateSales Date_Range Begin_DateEnd_Date Product_IDSales customer_idAvg_Days(set_id subject_idname first_dateuser_id project_idrecordslast_modstatus autoupdatecomments expiry_date expiry_id targetuser_id setversion_id is_versionedis_built dtime_builtpartbld_actseqrefresh_freq_id calendar_idbase_period_id last_ref_iddate_refreshed hist_periodshist_directive is_external is_terminal is_del_markis_lock_if_done no_of_actionsis_allow_tlogicdno_of_cycles_doneown_table_nameis_test_autoincis_lmt_autoincis_points_sens is_frozencurr_det_tbl_idreqd_det_tbl_id Lower_Value Upper_Value setversion_ididpointssdateedate$ basket_idNumber_of_Products store_sales store_cost store_margin sales_datestore_id customer_idNumber_of_Items Margin_Pct Promotion_IDAvg_Margin_Per_ItemAvg_Price_per_ItemAlcoholic_Beverages Baked_Goods Baking_Goods BeveragesBreakfast_Foods Canned_FoodsCanned_ProductsCaroselCheckoutDairyDeliEggs Frozen_FoodsHealth_and_Hygiene HouseholdMeatPackaged_Foods PeriodicalsProduceSeafood Snack_FoodsSnacks Starchy_Foods User_NameMessage Customer_ID Lower_Value Upper_ValueBin_NamePK r2<ý›[¸¸ Columns Id;Ěť/MeatŞ/Avg_Margin_Per_Itemˆgenderwlnamef is_frozenU calendar_idD first_date3 store_phone"low_fatcost˙= customer_idď5 product_idź/Packaged_FoodsŤ/Avg_Price_per_Item‰total_childrenxfnameg curr_det_tbl_idV base_period_idE user_id4 store_fax#units_per_case start_date product_id=Avg_Daysđ5 Store_Sales˝/ PeriodicalsŹ/Alcoholic_BeveragesŠnum_children_at_homeymih reqd_det_tbl_idW last_ref_idF project_id5first_opened_date$cases_per_palletend_date customer_idń4 customer_idž/Produce­/ Baked_Goods‹ educationzaddress1i)Week_Ending_DateX date_refreshedG records6last_remodel_date% shelf_width+Week_Ending_Date promotion_idň4 Store_Salesż/SeafoodŽ/ Baking_Goods. Lower_ValueŒdate_accnt_opened{address2j)SalesY hist_periodsH last_mod7 lease_sqft& shelf_height+Salesstore_idĐ3 product_idŔ/ Snack_FoodsŻ/ Beveragesž. Upper_Value member_card|address3kproduct_class_idZ hist_directiveI status8 store_sqft' shelf_depth Date_Range store_salesŃ3 customer_idÁ/Snacks°/Breakfast_FoodsŸ/ basket_idŽ occupation}address4lproduct_subcategory[ is_externalJ autoupdate9 grocery_sqft(store_id Begin_Date store_costŇ3 promotion_idÂ/ Starchy_Foodsą/ Canned_Foods /Number_of_Products houseowner~citymproduct_category\ is_terminalK comments: frozen_sqft) store_typeEnd_Date unit_salesÓ3store_id˛/Canned_ProductsĄ/ store_salesnum_cars_ownedstate_provincenproduct_department] is_del_markL expiry_date; meat_sqft* region_idproduct_class_id sales_dateÔ3 sales_dateł/Carosel˘/ store_cost€ postal_codeoproduct_family^ is_lock_if_doneM expiry_id< coffee_bar+ store_name product_id  basket_idŐ3 basket_id´/CheckoutŁ/ store_margincountryp setversion_id_ no_of_actionsN targetuser_id= video_store, store_number brand_name  store_marginÖ3Last_Days_Salesľ/Dairy¤/ sales_date‚customer_region_idq id` is_allow_tlogicdO setversion_id> salad_bar-store_street_address product_name & Begin_Date×3Penultimate_Days_SalesÇ1 Customer_IDś/DeliĽ/store_idƒphone1r pointsa no_of_cycles_doneP is_versioned? prepared_food. store_citySKU &Week_Ending_Date A User_NameB Lower_Valueˇ/EggsŚ/ customer_id„phone2s sdateb own_table_nameQ is_built@florist/ store_stateSRP  promotion_id AMessageB Upper_Value¸/ Frozen_Foods§/Number_of_Items… birthdatet edatec is_test_autoincR dtime_builtA set_id0store_postal_code gross_weightpromotion_district_idBBin_Nameš/Health_and_Hygiene¨/ Margin_Pct—, Product_ID†marital_statusu customer_idd is_lmt_autoincS partbld_actseqB subject_id1 store_country  net_weightpromotion_nameş/ HouseholdŠ/ Promotion_ID˜,Sales‡ yearly_incomev account_nume is_points_sensT refresh_freq_idC name2 store_manager!recyclable_package media_typePK r2<ĹŹlÄÄVirtual Tables; 3€select Current_Facts.product_id,Current_Facts.customer_id,Current_Facts.promotion_id,Current_Facts.store_id,Current_Facts.sales_date,Current_Facts.basket_id, case when Current_Facts.sales_date = (select max(dbo.Current_Facts.sales_date) from dbo.Current_Facts) then Current_Facts.store_sales else 0 end as Last_Days_Sales, case when dbo.Current_Facts.sales_date = (select min(Last_Two_Dates.Last_Two_Dates) from (select distinct top 2 Current_Facts.sales_date as Last_Two_Dates from Current_Facts order by Current_Facts.sales_date desc) Last_Two_Dates) then Current_Facts.store_sales else 0 end as Penultimate_Days_Sales from Current_Facts4Uselect top @Prompt('How Many Customers','N',,mono,free) Current_Facts.customer_id as customer_id, sum(Current_Facts.store_sales) as Store_Sales from Current_Facts where datediff(d,dbo.Current_Facts.sales_date,getdate())<=@Prompt('How Many Days','N',,mono,free) group by Current_Facts.customer_id order by sum(Current_Facts.store_sales) desc5ęselect top @Prompt('How Many Products','N',,mono,free) Current_Facts.product_id as product_id, sum(Current_Facts.store_sales) as Store_Sales from Current_Facts where Current_Facts.customer_id in (select distinct customer_id from (select top @Prompt('How Many Customers','N',,mono,free) Current_Facts.customer_id, sum(Current_Facts.store_sales) as Store_Sales from Current_Facts where datediff(d,dbo.Current_Facts.sales_date,getdate())<=@Prompt('How Many Days','N',,mono,free) group by Current_Facts.customer_id order by sum(Current_Facts.store_sales) desc) Top_N_Sales) and datediff(d,dbo.Current_Facts.sales_date,getdate())<=@Prompt('How Many Days','N',,mono,free) group by Current_Facts.product_id order by sum(Current_Facts.store_sales) desc&select distinct dateadd(wk,-@Prompt('No. of Weeks','N',,mono,free),(dbo.Current_Facts.sales_date - DATEPART(dw, dbo.Current_Facts.sales_date))+7) as Begin_Date, (dbo.Current_Facts.sales_date - DATEPART(dw, dbo.Current_Facts.sales_date))+7 as Week_Ending_Date from Current_Facts)űselect (dbo.Current_Facts.sales_date - DATEPART(dw, dbo.Current_Facts.sales_date))+7 as Week_Ending_Date, sum(Current_Facts.store_sales) as Sales from Current_Facts group by (dbo.Current_Facts.sales_date - DATEPART(dw, dbo.Current_Facts.sales_date))+7+űselect (dbo.Current_Facts.sales_date - DATEPART(dw, dbo.Current_Facts.sales_date))+7 as Week_Ending_Date, sum(Current_Facts.store_sales) as Sales from Current_Facts group by (dbo.Current_Facts.sales_date - DATEPART(dw, dbo.Current_Facts.sales_date))+7,&SELECT Top 5 Current_Facts.product_id as Product_ID, sum(Current_Facts.store_sales) as Sales FROM Current_Facts where Current_Facts.store_id = (select store.store_id from store where store.store_manager = @Variable('BOUSER') ) GROUP BY Current_Facts.product_id ORDER BY 2 DESC=Ýselect Current_Facts.customer_id, cast((datediff(d,min(Current_Facts.sales_date),max(Current_Facts.sales_date))) as float)/(count(*)-1) as Avg_Days from Current_Facts group by Current_Facts.customer_id having count(*) > 1.-select @Prompt('1st Bin','N',,mono,free) as Lower_Value, @Prompt('2nd Bin','N',,mono,free) as Upper_Value from syscolumns union select @Prompt('2nd Bin','N',,mono,free)+.01 as Lower_Value, @Prompt('3rd Bin','N',,mono,free) as Upper_Value from syscolumns union select @Prompt('3rd Bin','N',,mono,free)+.01 as Lower_Value, @Prompt('4th Bin','N',,mono,free) as Upper_Value from syscolumns union select @Prompt('4th Bin','N',,mono,free)+.01 as Lower_Value, @Prompt('5th Bin','N',,mono,free) as Upper_Value from syscolumns union select @Prompt('5th Bin','N',,mono,free)+.01 as Lower_Value, @Prompt('6th Bin','N',,mono,free) as Upper_Value from syscolumns union select @Prompt('6th Bin','N',,mono,free)+.01 as Lower_Value, @Prompt('7th Bin','N',,mono,free) as Upper_Value from syscolumns union select @Prompt('7th Bin','N',,mono,free)+.01 as Lower_Value, @Prompt('8th Bin','N',,mono,free) as Upper_Value from syscolumns union select @Prompt('8th Bin','N',,mono,free)+.01 as Lower_Value, @Prompt('9th Bin','N',,mono,free) as Upper_Value from syscolumns A•select 'Administrator' as User_Name, 'What Date' as Message from syscolumns union select 'Jose' as User_Name, 'Que Dia?' as Message from syscolumns1Ÿselect floor((10281*rand())) as Customer_ID from syscolumns union select floor((10281*rand())) as Customer_ID from syscolumns union select floor((10281*rand())) as Customer_ID from syscolumns union select floor((10281*rand())) as Customer_ID from syscolumns union select floor((10281*rand())) as Customer_ID from syscolumns union select floor((10281*rand())) as Customer_ID from syscolumns union select floor((10281*rand())) as Customer_ID from syscolumns union select floor((10281*rand())) as Customer_ID from syscolumns union select floor((10281*rand())) as Customer_ID from syscolumns union select floor((10281*rand())) as Customer_ID from syscolumnsBJselect 0 as Lower_Value, @Prompt('1st Bin','N',,mono,free) as Upper_Value, 'Below '+cast(@Variable('1st Bin') as char(4)) as Bin_Name from syscolumns union select @Prompt('1st Bin','N',,mono,free)+.01 as Lower_Value, @Prompt('2nd Bin','N',,mono,free) as Upper_Value, 'Between '+cast(@Variable('1st Bin') as char(4))+' and '+cast(@Variable('2nd Bin') as char(1)) as Bin_Name from syscolumns union select @Prompt('2nd Bin','N',,mono,free)+.01 as Lower_Value, 99999 as Upper_Value, 'Greater than '+cast(@Variable('2nd Bin') as char(4)) as Bin_Name from syscolumns PK r2<\RRObject_Formats;fî˙˙˙Arial ˙˙˙˙˙˙BOFormat˙˙˙˙BOListLPBOFirst˙˙˙˙ BOTimeFmt€€€€˙˙˙˙˙˙c˙˙˙Arial ˙˙€€€€€€€$€€€€€€€€$˙˙˙˙A˙˙˙Arial ˙˙€€€€€€€$€€€€€€€€$˙˙˙˙˙˙˙Arial ˙˙€€€€€€€!%˙˙˙˙˙˙–˙˙˙Arial ˙˙€€€€€€€˙˙˙˙˙˙3˙˙˙Arial ˙˙€€€€€€€˙˙˙˙˙˙4˙˙˙Arial ˙˙€€€€€€€ ˙˙˙˙˙˙u˙˙˙Arial ˙˙€€€€€€€$€€€€€€€€$˙˙˙˙B˙˙˙Arial ˙˙€€€€€€€$€€€€€€€€$˙˙˙˙ ˙˙˙Arial ˙˙€€€€€€€!%˙˙˙˙˙˙—˙˙˙Arial ˙˙€€€€€€€˙˙˙˙˙˙Í˙˙˙Arial ˙˙€€€€€€€˙˙˙˙˙˙š˙˙˙Arial ˙˙€€€€€€€˙˙˙˙˙˙Ť˙˙˙Arial ˙˙€€€€€€€€€€$˙˙˙˙˙˙e˙˙˙Arial ˙˙€€€€€€€$€€€€€€€€$˙˙˙˙2˙˙˙Arial ˙˙€€€€€€€$˙˙˙˙˙˙v˙˙˙Arial ˙˙€€€€€€€$€€€€€€€€$˙˙˙˙C˙˙˙Arial ˙˙€€€€€€€$€€€€€€€€$˙˙˙˙˝˙˙˙Arial ˙˙€€€€€€€$˙˙˙˙˙˙›˙˙˙Arial ˙˙€€€€€€€˙˙˙˙˙˙ŕ˙˙˙Arial ˙˙€€€˙˙˙˙˙˙œ˙˙˙Arial ˙˙€€€˙˙˙˙˙˙ˆ˙˙˙Arial ˙˙€€€€€€€ ˙˙˙˙˙˙­˙˙˙Arial ˙˙€€€˙˙˙˙˙˙f˙˙˙Arial ˙˙€€€€€€€$€€€€€€€€$˙˙˙˙3˙˙˙Arial ˙˙€€€€€€€$˙˙˙˙˙˙w˙˙˙Arial ˙˙€€€€€€€$€€€€€€€€$˙˙˙˙U˙˙˙Arial ˙˙€€€€€€€$€€€€€€€€$˙˙˙˙D˙˙˙Arial ˙˙€€€€€€€$€€€€€€€€$˙˙˙˙"˙˙˙Arial ˙˙€€€€€€€!%˙˙˙˙˙˙6˙˙˙Arial ˙˙€€€€€€€$˙˙˙˙˙˙Đ˙˙˙Arial ˙˙€€€€€€€˙˙˙˙˙˙˙˙˙Arial ˙˙€€€˙˙˙˙˙˙‰˙˙˙Arial ˙˙€€€€€€€!%˙˙˙˙˙˙4˙˙˙Arial ˙˙€€€€€€€$˙˙˙˙˙˙#˙˙˙Arial ˙˙€€€€€€€!%˙˙˙˙˙˙V˙˙˙Arial ˙˙€€€€€€€$€€€€€€€€$˙˙˙˙E˙˙˙Arial ˙˙€€€€€€€$€€€€€€€€$˙˙˙˙Ń˙˙˙Arial ˙˙€€€€€€€˙˙˙˙˙˙ž˙˙˙Arial ˙˙€€€€€€€ ˙˙˙˙˙˙Š˙˙˙Arial ˙˙€€€˙˙˙˙˙˙h˙˙˙Arial ˙˙€€€€€€€$€€€€€€€€$˙˙˙˙W˙˙˙Arial ˙˙€€€€€€€$€€€€€€€€$˙˙˙˙F˙˙˙Arial ˙˙€€€€€€€$€€€€€€€€$˙˙˙˙â˙˙˙Arial ˙˙€€€€€€€€€€$˙˙˙˙˙˙X˙˙˙Arial ˙˙€€€€€€€$€€€€€€€€$˙˙˙˙G˙˙˙Arial ˙˙€€€€€€€$€€€€€€€€$˙˙˙˙Ÿ˙˙˙Arial ˙˙€€€€€€€$˙˙˙˙˙˙ă˙˙˙Arial ˙˙€€€€€€€€€€$˙˙˙˙˙˙Ó˙˙˙Arial ˙˙€€€€€€€˙˙˙˙˙˙ä˙˙˙Arial ˙˙€€€€€€€ ˙˙˙˙˙˙Y˙˙˙Arial ˙˙€€€€€€€$€€€€€€€€$˙˙˙˙H˙˙˙Arial ˙˙€€€€€€€$€€€€€€€€$˙˙˙˙ ˙˙˙Arial ˙˙€€€€€€€$˙˙˙˙˙˙˙˙˙Arial ˙˙€€€€€€€!%˙˙˙˙˙˙Ô˙˙˙Arial ˙˙€€€€€€€˙˙˙˙˙˙Z˙˙˙Arial ˙˙€€€€€€€$€€€€€€€€$˙˙˙˙I˙˙˙Arial ˙˙€€€€€€€$€€€€€€€€$˙˙˙˙Ą˙˙˙Arial ˙˙€€€€€€€$˙˙˙˙˙˙˙˙˙Arial ˙˙€€€€€€€!%˙˙˙˙˙˙ž˙˙˙Arial ˙˙€€€€€€€$˙˙˙˙˙˙9˙˙˙Arial ˙˙€€€€€€€$˙˙˙˙˙˙Ő˙˙˙Arial ˙˙€€€€€€€˙˙˙˙˙˙l˙˙˙Arial ˙˙€€€€€€€$€€€€€€€€$˙˙˙˙[˙˙˙Arial ˙˙€€€€€€€$€€€€€€€€$˙˙˙˙J˙˙˙Arial ˙˙€€€€€€€$€€€€€€€€$˙˙˙˙ć˙˙˙Arial ˙˙€€€€€€€˙˙˙˙˙˙Ž˙˙˙Arial ˙˙€€€€€€€!%˙˙˙˙˙˙:˙˙˙Arial ˙˙€€€€€€€$˙˙˙˙˙˙m˙˙˙Arial ˙˙€€€€€€€$€€€€€€€€$˙˙˙˙K˙˙˙Arial ˙˙€€€€€€€$€€€€€€€€$˙˙˙˙Ł˙˙˙Arial ˙˙€€€€€€€$˙˙˙˙˙˙˙˙˙Arial ˙˙€€€€€€€!%˙˙˙˙˙˙¤˙˙˙Arial ˙˙€€€˙˙˙˙˙˙L˙˙˙Arial ˙˙€€€€€€€$€€€€€€€€$˙˙˙˙n˙˙˙Arial ˙˙€€€€€€€˙˙˙˙˙˙˙˙˙Arial ˙˙€€€€€€€€€€˙˙˙˙˙˙Ć˙˙˙Arial ˙˙€€€€€€€€€€$˙˙˙˙˙˙^˙˙˙Arial ˙˙€€€€€€€$€€€€€€€€$˙˙˙˙Ľ˙˙˙Arial ˙˙€€€€€€€$€€€€€€€€$˙˙˙˙M˙˙˙Arial ˙˙€€€€€€€$€€€€€€€€$˙˙˙˙ś˙˙˙Arial ˙˙€€€€€€€$˙˙˙˙˙˙˙˙˙Arial ˙˙€€€€€€€€€€$˙˙˙˙˙˙s˙˙˙Arial ˙˙€€€€€€€$€€€€€€€€$˙˙˙˙Ś˙˙˙Arial ˙˙€€€€€€€$˙˙˙˙˙˙N˙˙˙Arial ˙˙€€€€€€€$€€€€€€€€$˙˙˙˙˙˙˙Arial ˙˙€€€€€€€€€€˙˙˙˙˙˙-˙˙˙Arial ˙˙€€€€€€€ ˙˙˙˙˙˙–˙˙˙Arial ˙˙€€€˙˙˙˙˙˙§˙˙˙Arial ˙˙˙˙˙˙˙˙O˙˙˙Arial ˙˙€€€€€€€$€€€€€€€€$˙˙˙˙?˙˙˙Arial ˙˙€€€˙˙˙˙˙˙¨˙˙˙Arial ˙˙€€€€€€€$€€€€€€€€$˙˙˙˙P˙˙˙Arial ˙˙€€€€€€€$€€€€€€€€$˙˙˙˙˙˙˙Arial ˙˙€€€€€€€!%˙˙˙˙˙˙”˙˙˙Arial ˙˙€€€€€€€˙˙˙˙˙˙š˙˙˙Arial ˙˙€€€€€€€€€€˙˙˙˙˙˙1˙˙˙Arial ˙˙€€€€€€€$˙˙˙˙˙˙˙˙˙Arial ˙˙€€€€€€€!%˙˙˙˙˙˙•˙˙˙Arial ˙˙€€€€€€€˙˙˙˙˙˙ş˙˙˙Arial ˙˙€€€€€€€€€€$˙˙˙˙˙˙2˙˙˙Arial ˙˙€€€€€€€$˙˙˙˙˙˙PK r2<ŒüvWindowsPageFormat;V1.01Mercury V1 Platform Page Format)\Âő(đ?˙˙˙˙ BODateTimeÖ˙˙˙Żv%¤ţÍü winspoolSnagIt 8C:\Documents and Settings\All Users\Application Data\TechSmith\SnagIt 8\PrinterPortFileČSnagIt 8ÜěCď€ę odČČLetter˙˙˙˙DINU"°ěÁ•ű°SMTJ SnagIt 8 PrinterInputBinMANUALRESDLLUniresDLLOrientationPORTRAITPaperSizeLETTERResolutionOption3ColorMode24bppPK r2<ͤQŸ˜˜Object_ExtraFormats;fîcA–34uB —͚Ťe2vC˝›ŕœˆ­f3wUD"6Н‰4#VEўŠhWFâXGŸăÓäYH ÔZIĄž9Ől[JćŽ:mK٤LnĆ^ĽMśsŚN-–§O?¨P”š1•ş2PK r2<ډSź00BusinessObjects Reservedԋ|ԋ|ԋ|œIĐ˙˙˙˙¤IĐŹIĐ´IĐźIĐÄIĐĚIĐÔIĐÜIĐäIĐěIĐôIĐüIĐJĐ JĐJĐJĐ$JĐ,JĐ4JĐUNW_Storage/Tables/PK r2<ę域oUNW_Storage/Contexts/ContextsPK r2<IUNW_Storage/Contexts/PK r2<ßD!!|UNW_Storage/Dot_Tables/Dot_TablesPK r2<żUNW_Storage/Dot_Tables/PK r2<ôUNW_Storage/Connection/PK r2<)UNW_Storage/Parameters/PK r2>1ąUNW_Storage/Crystal_References/Crystal_ReferencesPK r2<> UNW_Storage/Crystal_References/PK r2<ßD!9{ UNW_Storage/ Upward_AggregateAware/ Upward_AggregateAwarePK r2<#Ö UNW_Storage/ Upward_AggregateAware/PK r2<) UNW_Storage/Dynamic_Objects_Descriptions/PK r2<ßD!E^ UNW_Storage/Dynamic_Classes_Descriptions/Dynamic_Classes_DescriptionsPK r2<)Ĺ UNW_Storage/Dynamic_Classes_Descriptions/PK r2<ßD!K UNW_Storage/Dynamic_Properties_Descriptions/Dynamic_Properties_DescriptionsPK r2<,y UNW_Storage/Dynamic_Properties_Descriptions/PK r2< Ă UNW_Storage/PK r2<˙ŮAí ResourceHeader|/B-Descriptor;PK r2zJJ(w ResourceHeader|/BusinessObjects ReservedPK r2< ResourceHeader|/PK r2<wN‘((5 Audit;PK r2<ßD! XML-LOV;PK r2<›ŐŤ Upward;PK `I;’ JLä PlatformPK r2< UNICODE ONPK r2<ßD! :Downward;PK r2Tables;PK r2<‚ĂzćÇćÇEObjects;PK r2<űäƒĚŒŒ) Columns;PK r2<ý›[¸¸ Ű Columns Id;PK r2<ĹŹlÄÄź1Virtual Tables;PK r2<\RR­GObject_Formats;PK r2<Œüvń™WindowsPageFormat;PK r2<ͤQŸ˜˜9ŸObject_ExtraFormats;PK r2<ډSź00ĽBusinessObjects ReservedPK r2