33
DirectQuery vs Vertipaq Modes in SSAS Tabular Model Julie Koesmarno http://www.mssqlgirl.com | Twitter: @mssqlgirl MCITP Database Administrator 2008 | MCITP Database Developer 2008 MCITP Business Intelligence Developer 2008 3 May 2012

DirectQuery vs Vertipaq Modes in SSAS Tabular Model new and flashy Tabular Model for Analysis Services has been highly pitched with the in-memory (VertiPaq) capability allowing for

Embed Size (px)

Citation preview

Page 1: DirectQuery vs Vertipaq Modes in SSAS Tabular Model new and flashy Tabular Model for Analysis Services has been highly pitched with the in-memory (VertiPaq) capability allowing for

DirectQuery vs Vertipaq Modes in SSAS Tabular Model

Julie Koesmarno http://www.mssqlgirl.com | Twitter: @mssqlgirl

MCITP Database Administrator 2008 | MCITP Database Developer 2008

MCITP Business Intelligence Developer 2008

3 May 2012

Page 2: DirectQuery vs Vertipaq Modes in SSAS Tabular Model new and flashy Tabular Model for Analysis Services has been highly pitched with the in-memory (VertiPaq) capability allowing for

Terminology

DirectQuery vs In-Memory

Hybrid Mode

PASS DW/BI VC 2

Agenda

3 May 2012

Page 3: DirectQuery vs Vertipaq Modes in SSAS Tabular Model new and flashy Tabular Model for Analysis Services has been highly pitched with the in-memory (VertiPaq) capability allowing for

The new and flashy Tabular Model for Analysis Services has been highly pitched with the in-memory (VertiPaq) capability allowing for complex queries to run very fast. This session with some live demo will uncover:

Advantages and disadvantages of using in-memory cache to store and query data

Restrictions on DirectQuery tabular model

Hybrid mode utilization

Impersonation and Partitioning techniques

Prerequisite:

Familiarity with basic Tabular Model project creation will be useful, but not mandatory

PASS DW/BI VC 3

Abstract

3 May 2012

Page 4: DirectQuery vs Vertipaq Modes in SSAS Tabular Model new and flashy Tabular Model for Analysis Services has been highly pitched with the in-memory (VertiPaq) capability allowing for

Terminology

Tabular Model Architecture and Solution

Page 5: DirectQuery vs Vertipaq Modes in SSAS Tabular Model new and flashy Tabular Model for Analysis Services has been highly pitched with the in-memory (VertiPaq) capability allowing for

PASS DW/BI VC 5

DirectQuery

Vertipaq

In-Memory

xVelocity Cached

3 May 2012

Page 6: DirectQuery vs Vertipaq Modes in SSAS Tabular Model new and flashy Tabular Model for Analysis Services has been highly pitched with the in-memory (VertiPaq) capability allowing for

PASS DW/BI VC 6

Tabular Model Architecture

Tabular Model

DirectQuery In-Memory

Third Party Application Excel Power View Reporting Services

SQL Server Databases Non SQL Server Databases

OData Files Cloud Services

3 May 2012

Page 7: DirectQuery vs Vertipaq Modes in SSAS Tabular Model new and flashy Tabular Model for Analysis Services has been highly pitched with the in-memory (VertiPaq) capability allowing for

Tabular Model Solutions

PASS DW/BI VC 7

Authoring (SSDT) Deployment Option

Connectivity

Database Properties

3 May 2012

Page 8: DirectQuery vs Vertipaq Modes in SSAS Tabular Model new and flashy Tabular Model for Analysis Services has been highly pitched with the in-memory (VertiPaq) capability allowing for

Execution

DirectQuery vs In-Memory

Page 9: DirectQuery vs Vertipaq Modes in SSAS Tabular Model new and flashy Tabular Model for Analysis Services has been highly pitched with the in-memory (VertiPaq) capability allowing for

Querying

PASS DW/BI VC 9

Data Access

Query

Data Sources DirectQuery

Process

In-Memory

DAX / MDX

VertiPaq SE SQL

DAX

3 May 2012

Page 10: DirectQuery vs Vertipaq Modes in SSAS Tabular Model new and flashy Tabular Model for Analysis Services has been highly pitched with the in-memory (VertiPaq) capability allowing for

DirectQuery Security

PASS DW/BI VC 10

Role

DirectQuery Impersonation

Impersonate Current User

Default (Data Source login)

Data Source Impersonation

Windows User

Service Account

DirectQuery

SQL

Query

3 May 2012

Page 11: DirectQuery vs Vertipaq Modes in SSAS Tabular Model new and flashy Tabular Model for Analysis Services has been highly pitched with the in-memory (VertiPaq) capability allowing for

VertiPaq SE

In-Memory

Process

Query

In-Memory Security

PASS DW/BI VC 11

Role

Row Level Security

Data Source Impersonation

3 May 2012

Page 12: DirectQuery vs Vertipaq Modes in SSAS Tabular Model new and flashy Tabular Model for Analysis Services has been highly pitched with the in-memory (VertiPaq) capability allowing for

Design

DirectQuery vs In-Memory

Page 13: DirectQuery vs Vertipaq Modes in SSAS Tabular Model new and flashy Tabular Model for Analysis Services has been highly pitched with the in-memory (VertiPaq) capability allowing for

Semantic differences

xVelocity in-memory analytics engine (VertiPaq)

SQL Server

No Calculated Column in DirectQuery

PASS DW/BI VC 13

Formula Compatibility

3 May 2012

Page 14: DirectQuery vs Vertipaq Modes in SSAS Tabular Model new and flashy Tabular Model for Analysis Services has been highly pitched with the in-memory (VertiPaq) capability allowing for

Some DAX Functions are not supported in DirectQuery:

No equivalent calculations in relational engine

No equivalent SQL expressions

Performance of converted expressions

E.g. TOTALYTD, SAMEPERIODLASTYEAR

More information on BOL: http://msdn.microsoft.com/en-us/library/hh213006.aspx

PASS DW/BI VC 14

DAX Functions

3 May 2012

Page 15: DirectQuery vs Vertipaq Modes in SSAS Tabular Model new and flashy Tabular Model for Analysis Services has been highly pitched with the in-memory (VertiPaq) capability allowing for

Administration

DirectQuery vs In-Memory

Page 16: DirectQuery vs Vertipaq Modes in SSAS Tabular Model new and flashy Tabular Model for Analysis Services has been highly pitched with the in-memory (VertiPaq) capability allowing for

Mode Database Table Partition

Process Default × × ×

Process Full × × ×

Process Data × ×

Process Clear × × ×

Process Defrag ×

Process Add ×

Process Recalc ×

PASS DW/BI VC 16

Processing Options (In-Memory)

Further reading: http://msdn.microsoft.com/en-us/library/hh758414.aspx

3 May 2012

Page 17: DirectQuery vs Vertipaq Modes in SSAS Tabular Model new and flashy Tabular Model for Analysis Services has been highly pitched with the in-memory (VertiPaq) capability allowing for

One partition in Tabular Model

Can take advantage of Partitioning and ColumnStore Index technology on SQL Server 2012

Partitioning / ColumnStore management done at the source database level

PASS DW/BI VC 17

Partitioning in DirectQuery

3 May 2012

Page 18: DirectQuery vs Vertipaq Modes in SSAS Tabular Model new and flashy Tabular Model for Analysis Services has been highly pitched with the in-memory (VertiPaq) capability allowing for

In-Memory can have multiple mutually exclusive partitions

To eliminate unnecessary processing and processor load on the AS servers

PASS DW/BI VC 18

Partitioning in In-Memory

C u r r e n t

Mar 2012

Jan 2012

Feb 2012

In-Memory Partitions Process

3 May 2012

Page 19: DirectQuery vs Vertipaq Modes in SSAS Tabular Model new and flashy Tabular Model for Analysis Services has been highly pitched with the in-memory (VertiPaq) capability allowing for

Pros and Cons

DirectQuery vs In-Memory

Page 20: DirectQuery vs Vertipaq Modes in SSAS Tabular Model new and flashy Tabular Model for Analysis Services has been highly pitched with the in-memory (VertiPaq) capability allowing for

ALL functionality of Tabular Model

Calculated Columns, ALL DAX functions

Row Level security

xVelocity in-memory analytics engine

Many choices of client tool

Excel, Power View, SSRS, MDX client*

Many supported data sources

PASS DW/BI VC 20

In-Memory - Pros

3 May 2012

Page 21: DirectQuery vs Vertipaq Modes in SSAS Tabular Model new and flashy Tabular Model for Analysis Services has been highly pitched with the in-memory (VertiPaq) capability allowing for

AS requires Memory & CPU resources

Caching

Processing

Querying

Diligent Partitioning and Processing

Out of date data

PASS DW/BI VC 21

In-Memory - Cons

3 May 2012

Page 22: DirectQuery vs Vertipaq Modes in SSAS Tabular Model new and flashy Tabular Model for Analysis Services has been highly pitched with the in-memory (VertiPaq) capability allowing for

Real time access

Scalable

SQL Server permission

SQL Server optimisation

Consistency

One Partition to manage

No processing required

PASS DW/BI VC 22

DirectQuery - Pros

3 May 2012

Page 23: DirectQuery vs Vertipaq Modes in SSAS Tabular Model new and flashy Tabular Model for Analysis Services has been highly pitched with the in-memory (VertiPaq) capability allowing for

Restricted DAX functions

Restricted client tools: PowerView, SSRS

No Row Level Security

Unless defined at the source Database

No Calculated Columns

PASS DW/BI VC 23

DirectQuery - Cons

3 May 2012

Page 24: DirectQuery vs Vertipaq Modes in SSAS Tabular Model new and flashy Tabular Model for Analysis Services has been highly pitched with the in-memory (VertiPaq) capability allowing for

Hybrid Mode

The best of both worlds

Page 25: DirectQuery vs Vertipaq Modes in SSAS Tabular Model new and flashy Tabular Model for Analysis Services has been highly pitched with the in-memory (VertiPaq) capability allowing for

Tabular Model Solutions

PASS DW/BI VC 25

Connection String:

DirectQueryMode=DirectQuery

DirectQueryMode=In-Memory

Query Mode

DirectQuery

DirectQuery with In-Memory

In-Memory with DirectQuery

In-Memory

DirectQueryMode

On

Off

3 May 2012

Page 26: DirectQuery vs Vertipaq Modes in SSAS Tabular Model new and flashy Tabular Model for Analysis Services has been highly pitched with the in-memory (VertiPaq) capability allowing for

One Partition for DirectQuery

Processing Option: Never process this partition

Multiple Partitions for In-Memory (No Overlap)

PASS DW/BI VC 26

Partitioning for Hybrid Mode

C u r r e n t

Mar 2012

Jan 2012

Feb 2012 In-Memory Partitions

DirectQuery Partition

3 May 2012

Page 27: DirectQuery vs Vertipaq Modes in SSAS Tabular Model new and flashy Tabular Model for Analysis Services has been highly pitched with the in-memory (VertiPaq) capability allowing for

Inconsistency

Data – stale data in Cache

Calculations – semantic differences xVelocity vs SQL

Security

DirectQuery Design

Flexibility at run time / client tools

In-Memory (Excel) or DirectQuery (Real time)

PASS DW/BI VC 27

Implications

3 May 2012

Page 28: DirectQuery vs Vertipaq Modes in SSAS Tabular Model new and flashy Tabular Model for Analysis Services has been highly pitched with the in-memory (VertiPaq) capability allowing for

Wrap Up

Page 29: DirectQuery vs Vertipaq Modes in SSAS Tabular Model new and flashy Tabular Model for Analysis Services has been highly pitched with the in-memory (VertiPaq) capability allowing for

In-Memory Mode (default)

DirectQuery Mode

DirectQuery only

DirectQuery with In-Memory

In-Memory with DirectQuery

PASS DW/BI VC 29

Tabular Model Modes

3 May 2012

Page 30: DirectQuery vs Vertipaq Modes in SSAS Tabular Model new and flashy Tabular Model for Analysis Services has been highly pitched with the in-memory (VertiPaq) capability allowing for

SQL Server database is optimised

Columnstore Index

Partitioning

Contains required most business rules

High Volume

Can import non-SQL data into one SQL Server database which will be the source

PASS DW/BI VC 30

Do I DirectQuery?

3 May 2012

Page 32: DirectQuery vs Vertipaq Modes in SSAS Tabular Model new and flashy Tabular Model for Analysis Services has been highly pitched with the in-memory (VertiPaq) capability allowing for

Q & A

3 May 2012 PASS DW/BI VC 32

[email protected]

http://www.mssqlgirl.com

http://au.linkedin.com/in/juliekoesmarno

@mssqlgirl

Page 33: DirectQuery vs Vertipaq Modes in SSAS Tabular Model new and flashy Tabular Model for Analysis Services has been highly pitched with the in-memory (VertiPaq) capability allowing for

Thank you!