powerpoint presentation · 2019-08-27 · presentation layer . that enhances user interactions with...

34
www.solverglobal.com

Upload: others

Post on 21-May-2020

1 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: PowerPoint Presentation · 2019-08-27 · presentation layer . that enhances user interactions with data oProvides a . semantic layer . that translates database structure into business

www.solverglobal.com

Page 2: PowerPoint Presentation · 2019-08-27 · presentation layer . that enhances user interactions with data oProvides a . semantic layer . that translates database structure into business

www.solverglobal.com

Microsoft BI Stack (SSAS) & BI360

Page 3: PowerPoint Presentation · 2019-08-27 · presentation layer . that enhances user interactions with data oProvides a . semantic layer . that translates database structure into business

www.solverglobal.com

8/21 & 8/22/2019

[email protected]

Toby PrinceSenior Consultant at Solver

Page 4: PowerPoint Presentation · 2019-08-27 · presentation layer . that enhances user interactions with data oProvides a . semantic layer . that translates database structure into business

www.solverglobal.com

Session Objectives

• Provide a brief introduction to SQL Server Analysis Services (SSAS)

• Present a business case and use case for combining BI360 Data Warehouse, Power BI & SSAS

Page 5: PowerPoint Presentation · 2019-08-27 · presentation layer . that enhances user interactions with data oProvides a . semantic layer . that translates database structure into business

www.solverglobal.com

Session Agenda

• SSAS Overview (business case)• Demo (use case)• Key Takeaways and Resources• Q & A

Page 6: PowerPoint Presentation · 2019-08-27 · presentation layer . that enhances user interactions with data oProvides a . semantic layer . that translates database structure into business

www.solverglobal.com

What is SSAS?• SSAS = SQL Server Analysis Services• Online analytical data engine used in ad hoc reporting and business

analytics• Stores data, hierarchies, calculations, etc. in a highly compressed format

that enables instant responses to user queries• Part of the Microsoft “BI Stack”, a suite of optional SQL server add-on

components that also includes SSIS (SQL Server Integration Services) and SSRS (SQL Server Reporting Services)

Page 7: PowerPoint Presentation · 2019-08-27 · presentation layer . that enhances user interactions with data oProvides a . semantic layer . that translates database structure into business

www.solverglobal.com

Two SSAS Modeling Modes

NOTE: Can have only one mode per SSAS Instance

Page 8: PowerPoint Presentation · 2019-08-27 · presentation layer . that enhances user interactions with data oProvides a . semantic layer . that translates database structure into business

www.solverglobal.com

How Does SSAS Differ from SQL?• Like SQL Server RDBMS, it’s essentially a database platform, but…• Intended for highly compressed, simplified data sets

o E.g. not the big, sprawling database schemas, comprised of 100’s or 1000’s of tables we’re used to seeing in SQL

oData models tend to be subject matter specific, e.g. Sales Orders, GL

• Built for reporting and rapid data retrievalo Thanks to aggregations and other compression methods SSAS can leverage for

youo Limited or no write-back capability (depending on which modeling mode)

Page 9: PowerPoint Presentation · 2019-08-27 · presentation layer . that enhances user interactions with data oProvides a . semantic layer . that translates database structure into business

www.solverglobal.com

How Does SSAS Differ from SQL?• Uses a different query language, either DAX or MDX…

oDAX (Data Analysis Expressions) is used with Tabular mode, also the query language of Power BI desktop

oMDX (Multidimensional Expressions) is used with Multi-dimensional mode (Cubes)

• Complement to your RDBMSoPart of the BI presentation layer that enhances user interactions with dataoProvides a semantic layer that translates database structure into business

user oriented terms and constructs

Page 10: PowerPoint Presentation · 2019-08-27 · presentation layer . that enhances user interactions with data oProvides a . semantic layer . that translates database structure into business

www.solverglobal.com

Why SSAS?Business Case… 1. BI360DW Private Host (4.x or 5.x)2. Want to use Power BI Desktop, Power Pivot, etc. with data in BI360DW3. Mark all that apply…Have large datasets (e.g. >20M records) stored in BI360 modules, for

example point of sale data, GL transaction detail, etc.Have a diverse user group with varied levels of proficiency or accessUsing BI360 tree functionality for reporting hierarchies

Page 11: PowerPoint Presentation · 2019-08-27 · presentation layer . that enhances user interactions with data oProvides a . semantic layer . that translates database structure into business

www.solverglobal.com

Why SSAS?How SSAS can help…• Scale up by moving data and processing workloads on to a dedicated

server, and off of end-user workstations• Centralize data modeling tasks (single version of the truth)• Leverage security features (e.g. row level security) to create user roles

and specify data access• Support for parent-child hierarchies, ragged hierarchies, custom rollup

operators, etc.

Page 12: PowerPoint Presentation · 2019-08-27 · presentation layer . that enhances user interactions with data oProvides a . semantic layer . that translates database structure into business

www.solverglobal.com

Why SSAS?Tradeoffs…• Additional server best practice is to run SQL RDBMS and SSAS on

separate servers• Visual Studio design environment not (quite) as intuitive or full

featured as PBI Desktop• Supports fewer data sources than PBI Desktop but can stage in

BI360DW first

Page 13: PowerPoint Presentation · 2019-08-27 · presentation layer . that enhances user interactions with data oProvides a . semantic layer . that translates database structure into business

www.solverglobal.com

Why SSAS?Power BI Service

Power BI gateway

DatasetsVisualizationsDashboards

BI360DW

ReportsScheduled

updates, or live connection to

SSASTables, Views, Queries

Analysis Services (SSAS)

Data Model

Pivot Tables

Charts, Maps, etc.

BI Developer(s)

Business Users

Page 14: PowerPoint Presentation · 2019-08-27 · presentation layer . that enhances user interactions with data oProvides a . semantic layer . that translates database structure into business

www.solverglobal.com

Demo Use Case…

1. Identify source tables, write SQL (optional), etc.2. Create SSAS tabular data model in Visual Studio3. Import demo data from BI360 (4.x) Revenue module4. Prep the data: hide/relabel columns, add measures, etc.5. Deploy the model to an SSAS server6. Connect from Excel using a Pivot Table7. Connect from Power BI Desktop

Page 15: PowerPoint Presentation · 2019-08-27 · presentation layer . that enhances user interactions with data oProvides a . semantic layer . that translates database structure into business

www.solverglobal.com

Some Tabular Vocabulary…

• Tables and Columns – basic units of organization in a tabular model• Data Analysis Expressions (DAX) – native formula and query language

for PowerPivot, Power BI Desktop and SSAS Tabular models• Calculated Column – custom column derived using DAX• Measure – calculation of a quantitative value, using DAX, for use in a

reporting client• Hierarchy - metadata that define relationships between two or more

columns in a table

Page 16: PowerPoint Presentation · 2019-08-27 · presentation layer . that enhances user interactions with data oProvides a . semantic layer . that translates database structure into business

www.solverglobal.com

Demo…

Page 17: PowerPoint Presentation · 2019-08-27 · presentation layer . that enhances user interactions with data oProvides a . semantic layer . that translates database structure into business

www.solverglobal.com

Key Takeaways & Resources

• Using SSAS with BI30DW can turbo charge your BI experience

• Private host only – no direct connection to BI360 cloud (yet)

• Two SSAS modes: Tabular or Multidimensional

• Get to know your BI360DW table structure

• Learning through trial and error…be patient

• Bonus Slides• Article: “Comparing tabular and

multidimensional solutions” at: docs.microsoft.com

• SQLBI: www.sqlbi.com• PowerPivot Pro:

powerpivotpro.com

Page 18: PowerPoint Presentation · 2019-08-27 · presentation layer . that enhances user interactions with data oProvides a . semantic layer . that translates database structure into business

www.solverglobal.com

Additional Slides

• Comparison of Two SSAS Modeling Modes• SQL Code Samples From Demo

Page 19: PowerPoint Presentation · 2019-08-27 · presentation layer . that enhances user interactions with data oProvides a . semantic layer . that translates database structure into business

www.solverglobal.com

Two SSAS Modeling Modes…Multidimensional Tabular

When Released SQL Server 2000 and later SQL Server 2012 and later

Storage Mode On Disk In-memory

Data Modeling Approach OLAP modeling constructs: Cube, dimensions & measures

Relational modeling constructs: Tabular model, tables & columns

Query/Business Logic Language

MDX (Multidimensional Expressions)

DAX (Data Analysis Expressions)

Calculated Measures Yes Yes

Hierarchies Yes Yes

Parent-child Hierarchies Yes No (Can use workaround in DAX)

Ragged Hierarchies Yes Yes (Depends on SSAS release)

Custom Rollups Yes No

Calculated Columns No Yes

Page 20: PowerPoint Presentation · 2019-08-27 · presentation layer . that enhances user interactions with data oProvides a . semantic layer . that translates database structure into business

www.solverglobal.com

Two SSAS Modeling Modes…

Page 21: PowerPoint Presentation · 2019-08-27 · presentation layer . that enhances user interactions with data oProvides a . semantic layer . that translates database structure into business

www.solverglobal.com

Which SSAS Mode is Right for You?• Consider Multidimensional If…

oAlready familiar with Cubes and MDXoDealing with very large data volumesoUsing trees in BI360DW these are essentially parent-child hierarchies, SSAS

multidimensional has an equivalent dimension typeoNeed to embed calculations, custom rollup operators, etc. within hierarchies

• Consider Tabular If…oNeed to get up and running quickly tabular modeling concepts and DAX are

already familiar if you’ve used Power BI desktopoUsing dimension table attributes (columns) to store hierarchieso Interested in Azure Analysis Services

Page 22: PowerPoint Presentation · 2019-08-27 · presentation layer . that enhances user interactions with data oProvides a . semantic layer . that translates database structure into business

www.solverglobal.com

SQL Code Samples

OverviewBI360DW contains several metadata tables that translate the familiar labels you see in BI360 applications to their equivalent table and column names in the SQL server database. You can query these metadata tables to identify source tables and columns to use when building data models in Visual Studio or Power BI.

Note: the naming and content of these tables differ between our 4.x and 5.x versions. We include examples from both 4.x and 5.x versions on the subsequent slides.

Page 23: PowerPoint Presentation · 2019-08-27 · presentation layer . that enhances user interactions with data oProvides a . semantic layer . that translates database structure into business

www.solverglobal.com

SQL Code Samples

OverviewUse these SQL Code samples to obtain information on…

• Module (fact) table names• Dimension table names• Module attributes (columns in module tables)• Dimension attributes (columns in dimension tables)

Page 24: PowerPoint Presentation · 2019-08-27 · presentation layer . that enhances user interactions with data oProvides a . semantic layer . that translates database structure into business

www.solverglobal.com

SQL Code SamplesList Modules - v 4.x

SELECT [Module],[ModuleName],'f_Trans_'+Module AS TableNameFROM [dbo].[ModuleLabel]

WHERE InUse = 1

Page 25: PowerPoint Presentation · 2019-08-27 · presentation layer . that enhances user interactions with data oProvides a . semantic layer . that translates database structure into business

www.solverglobal.com

SQL Code SamplesList Dimension Tables - v 4.x

--Lists Dimensions that are linked to the Module specified in the Where clause

SELECT [Module],[Field] AS Dimension,[Label] AS DimLabel,CASE WHEN [Field] = 'TimePeriod'

THEN 'd_Time' ELSE 'd_'+Field END AS TableNameFROM [dbo].[DimLabel]

WHERE Module = 'RV' AND InUse = 1

Page 26: PowerPoint Presentation · 2019-08-27 · presentation layer . that enhances user interactions with data oProvides a . semantic layer . that translates database structure into business

www.solverglobal.com

SQL Code SamplesList Dimension Attributes - v 4.x

--Lists attributes (columns) for the Dimension specified in the Where clause

SELECT[Dimension],[Field],[Label],[DataType]FROM [dbo].[DimAttribute]

WHERE Dimension = 'Dim0'And InUse = 1

Page 27: PowerPoint Presentation · 2019-08-27 · presentation layer . that enhances user interactions with data oProvides a . semantic layer . that translates database structure into business

www.solverglobal.com

SQL Code SamplesList Module Attributes - v 4.x

--Lists attributes (columns) for the Module specified in the Where clause

SELECT[Module],[Field],[Label],[DataType]FROM [dbo].[ModuleAttribute]

WHERE Module = 'RV'And InUse = 1

Page 28: PowerPoint Presentation · 2019-08-27 · presentation layer . that enhances user interactions with data oProvides a . semantic layer . that translates database structure into business

www.solverglobal.com

SQL Code SamplesList Modules - v 5.x

SELECT[ShortLabel] AS Module,[Label] AS ModuleName,[TableName] FROM [meta].[ModuleHeader]

Page 29: PowerPoint Presentation · 2019-08-27 · presentation layer . that enhances user interactions with data oProvides a . semantic layer . that translates database structure into business

www.solverglobal.com

SQL Code SamplesList Dimension Tables - v 5.x

--Lists Dimensions that are linked to the Module specified in the Where clause

SELECT t2.ShortLabel AS Module,t3.ShortLabel AS Dimension,t3.Label AS DimLabel,t3.TableNameFROM[meta].[ModuleDimensionMap] t1Join [meta].[ModuleHeader] t2 on t1.ModuleId = t2.IdLeft Join [meta].[DimensionHeader] t3 on t1.DimensionId = t3.Id

WHERE t2.ShortLabel = 'GL'

Page 30: PowerPoint Presentation · 2019-08-27 · presentation layer . that enhances user interactions with data oProvides a . semantic layer . that translates database structure into business

www.solverglobal.com

SQL Code SamplesList Dimension Attributes- v 5.x

--Lists attributes (columns) for the Dimension specified in the Where clause

SELECT t1.[ShortLabel] AS Dimension,t2.[ColumnName] AS Field,t2.Label,[DataType]FROM [meta].[DimensionHeader] t1Join [meta].[DimensionAttribute] t2 on t1.ID = t2.[DimensionId]

WHERE t1.ShortLabel = 'Dim0' and t2.IsVisible = 1

ORDER BY t2.ColumnOrder

Page 31: PowerPoint Presentation · 2019-08-27 · presentation layer . that enhances user interactions with data oProvides a . semantic layer . that translates database structure into business

www.solverglobal.com

SQL Code SamplesList Module Attributes - v 5.x

--Lists attributes (columns) for the Module specified in the Where clause

SELECTt1.[ShortLabel] AS Module,t2.[ColumnName] AS Field,t2.[Label] AS Label,t2.[DataType]FROM [meta].[ModuleHeader] t1Join [meta].[ModuleAttribute] t2 on t1.Id = t2.ModuleId

WHEREt1.ShortLabel = 'GL'And IsVisible = 1

Order by t2.ColumnOrder

Page 32: PowerPoint Presentation · 2019-08-27 · presentation layer . that enhances user interactions with data oProvides a . semantic layer . that translates database structure into business

www.solverglobal.com

SQL Code Sample – Time TableSQL Query/View for Time Dimension

--CREATE VIEW [dbo].[SSAS_Dim_Time] AS

SELECT [MemberId],CAST(CAST([CalendarMonth] AS VARCHAR(2)) + '/' + CAST([CalendarDay] AS VARCHAR(2)) + '/' + CAST([CalendarYear] AS VARCHAR(4)) AS DATETIME) AS PeriodDate,[FYPeriod] As FiscalPeriod,[PeriodStart] As FiscalPeriodStart, [PeriodEnd] As FiscalPeriodEnd,[FYWeek] As FiscalWeek, [FYPeriodInYear] As FiscalPeriodInYear,[FYQuarter] As FiscalQuarter, [FYYear] As FiscalYear,[CalendarDay] , [CalendarMonth], [CalendarYear], [Day] AS [WeekDay],[FYWeekLabel] AS FiscalWeekLabel,[FYMonthLabel] AS FiscalMonthLabel,[FYQuarterLabel] AS FiscalQuarterLabel,CAST([FYYear] AS VARCHAR(4)) AS FiscalYearLabelFROM [dbo].[d_Time]

This example works with both 4.x and5.x versions, can be used as a query orview, and adds a new column with thedate/time equivalent of each MemberID in the d_Time table.

This can be useful when using d_Timeas the source for a date table in an SSASdata model.

Page 33: PowerPoint Presentation · 2019-08-27 · presentation layer . that enhances user interactions with data oProvides a . semantic layer . that translates database structure into business

www.solverglobal.comwww.solverglobal.com

THANK YOU!• Toby Prince• Consultant at Solver• [email protected]

Page 34: PowerPoint Presentation · 2019-08-27 · presentation layer . that enhances user interactions with data oProvides a . semantic layer . that translates database structure into business

www.solverglobal.com