Beruflich Dokumente
Kultur Dokumente
Boinon Stéphane
March 2018
SSAS SQL SERVER 2016-2017 What’s new
2
01 SSAS SQL SERVER 2016 What’s new (Introduction)
Analysis Services (SSAS) is an online analytical data engine used in decision support and business
analytics. It provides analytical data for business reports and client applications such as Reporting
Services reports, Power BI, Excel, and other third-party data visualization tools
SSAS supports two modeling modes : Multidimensional (including a data mining engine) and 3
Tabular (based on xVelocity in-memory columnar database and analytics engine used in Power BI)
01 SSAS SQL SERVER 2016 What’s new (Introduction)
You can call into AMO from managed code or use PowerShell cmdlets for selected operations
• AMO has been refactored to include a second assembly Microsoft.AnalysisServices.Core
• This assembly includes common classes across SSAS modes: e.g. server, database, role
The command takes an object definition and returns either an empty result set or detailed error
information if the object is corrupted
• It can be run on demand if an administrator suspects problems with the data or model
• DBCC runs different checks depending on whether the model is Multidimensional or
Tabular
5
More details on DBCC commands can be found on this article.
01 SSAS SQL SERVER 2016 What’s new (Introduction)
With SSAS 2016 Tabular models (compatibility level 1200), all tabular models can benefit from:
- Parallel processing of multiple table partitions
- Support for Visual Studio Configuration manager
- Improved DAX formula editing (multi-line, tabs, comments)
- Formula fix up (renaming objects will automatically update formula references)
- New behaviors with DAX variables and new DAX functions (~59 including CALENDAR, DATEDIFF,
MEDIAN, ISEMPTY, GROUPBY, INTERSECT, UNION, CROSSFILTER, SIN, COS, EVEN, ODD, EXP…) 6
- Saving incomplete measures although all measures must be complete to deploy the project.
02 SSAS SQL SERVER 2016 Tabular (Development)
New features for Tabular 1200 models only are grouped by sub-category:
• Development
• Management
7
02 SSAS SQL SERVER 2016 Tabular (Development)
SSAS 2016 Tabular mode (Bi-directional cross filters)
Bi-directional cross filtering allows developers to define how filter context propagates
between related tables
• It allows cross-filtering across a table relationship in two directions rather than one direction,
which has always been a default feature in tabular models.
• Bi-directional filters on both sides of a bridging table will solve the “many-to-many” relationships
problem without the need to write DAX formulas as hand-crafted DAX workarounds for
propagating filter context across table relationships.
8
More detailed explanations can be found on following Microsoft tutorial page
02 SSAS SQL SERVER 2016 Tabular (Development)
SSAS 2016 Tabular mode (Display folders, to organize model elements into logical groups)
Display folders are now available for tabular 1200 models. Defined in SQL Server Data Tools
and rendered in client applications like Excel or Power BI Desktop.
• Display folders help organize large numbers of measures or Dimension attribute columns into
individual folders, adding a visual hierarchy for easier navigation in field lists.
• It is possible to assign one single measure or columns to multiple display folders or to nest display
folders by concatenating them using the semicolon.
• Depending on the client tool (Excel, SSMS, Power BI desktop, Reporting Services query Designer)
9
displayed folders behave a bit differently for measures.
02 SSAS SQL SERVER 2016 Tabular (Development)
SSAS 2016 Tabular mode (Translations, to view models in a preferred language)
Updates to the formula bar help write formulas with more ease by differentiating functions,
fields and measures using syntax coloring.
• It provides intelligent function, field suggestions that tells if parts of any DAX expression are wrong
using error ‘squiggles’. Auto-updates any measures referencing a column or table that is renamed
• It also allows to use multiple lines (Alt + Enter) and indentation (Tab). The formula bar now also
allows to write comments as part of your measures.
• Use variables in a DAX expression to break up a complex expression into a series of easier-to-read
11
expressions. Variables provides reusability of logic, readability and improves query performance.
02 SSAS SQL SERVER 2016 Tabular (Development)
SSAS 2016 Tabular model (Direct Query mode enhancements)
By default, tabular models use an in-memory cache to store and query data. However, large data
sets can exceed available memory, and data freshness requirements can be difficult if not impossible
to achieve on a regular processing schedule. DirectQuery overcomes these limitations while also
leveraging RDBMS features making query execution more efficient.
• You can now use DirectQuery on a model containing calculated columns but not calculated tables;
• You are no longer restricted to using SQL Server as a data source. 12
For a detailed list of improvements on Direct Query mode see this Microsoft article.
03 SSAS SQL SERVER 2016 Tabular (Management)
New 1200 model Management features:
• Tabular Object Model (TOM)
• Improved SSDT modeling performance, using TMSL (Tabular Model Scripting Language)
A Tabular model is a logical representation of Database, Connection, tables, tables partitions and
relationships for analytical purposes. Tabular model also includes other features like :
- Calculated columns, evaluated expressions that generate a column in a table, where a new value is
calculated and stored for each row in the table.
- Calculated Measures, stored expressions that are evaluated upon request once the model is
deployed.
- Hierarchies of attributes to provide a richer drill-up and drill-down experience,
- Perspectives to simplify or focus the model into a smaller portion of it,
- Key Performance Indicators and many other features included.
In SQL Server 2016, AMO is refactored into multiple assemblies. Generic classes such as Server,
Database, and Roles are in the Microsoft.AnalysisServices.Core Namespace. Multidimensional-
specific APIs remain in Microsoft.AnalysisServices Namespace.
13
03 SSAS SQL SERVER 2016 Tabular (Management)
New 1200 model Management features (Tabular Object Model)
14
03 SSAS SQL SERVER 2016 Tabular (Management)
New 1200 model Management features (Tabular Model Scripting Language)
TSML describes and manages SSAS objects with JSON format to replace former XMLA format
• SSMS database commands can produce TMSL scripts, including: Create, Alter, Delete, Backup,
Restore, Attach, and Detach. Output is Tabular Model Scripting Language (TMSL) in JSON format.
• Analysis Services Execute DDL or DML task now also accepts Tabular Model Scripting Language15
(TMSL) commands so does SSAS PowerShell cmdlet Invoke-Analysis Services command.
04 SSAS SQL SERVER 2016 Multidimensional
SSAS 2016 Multidimensional mode (main new features)
• It's now possible to do a drill through in a Excel PivotTable when there is a multiselect on a filter or
a slicer (only works if you are using SSAS 2016 server version)
• Excel PivotTables are now optimized when totals and subtotals are turned off
• In this case, better optimized MDX queries are generating, delivering performance benefits for 16
both MOLAP and tabular models
05 SSAS SQL SERVER 2016 Backward compatibility
SSAS 2016 backward compatibility
17
06 SSAS SQL SERVER 2016 Editions
SSAS 2016 supported features by SQL server editions
18
07 SSAS SQL SERVER 2016 Self Pace Labs
Exploring What's New in SQL Server 2016 Analysis Services (Duration 2h)
In this lab you will explore the new features delivered with SQL Server 2016 Analysis Services.
This will involve creating and monitoring Extended Events (xEvents), upgrading a tabular project to
SQL Server 2016, working with Visual Studio Configurations, implementing new calculation
capabilities, implementing new table relationship capabilities.
Then configuring display folders, managing model translations, working with the new Tabular Model
Scripting Language (TMSL), working with PowerShell, and also working with the new DirectQuery
mode capabilities.
Note: The majority of new features delivered with SQL Server 2016 Analysis Services are for tabular
mode, and so this lab focuses on tabular model development only.
A free PDF book named Introducing Microsoft SQL Server 2016: Mission-Critical Applications,
Deeper Insights, Hyperscale Cloud--Preview 2 is available for download at following url.
It includes, in Chapter 6 More Analytics, some detailed explanations about some enhancements to
tabular models present in SQL server 2016 (DirectQuery mode, calculated tables, Bidirectional cross-
filtering, new DAX functions, variables in DAX).
19
08 SSAS SQL SERVER 2017 What’s new (Tabular)
SASS 2107 main new features synthesis
20
08 SSAS SQL SERVER 2017 What’s new (Tabular)
New 1400 level including compatibility level in Azure Analysis Services ensuring a
symmetric modeling capability across on-premises and the cloud.
• New infrastructure for data connectivity and ingestion into tabular models with support for TOM
APIs and TMSL scripting including :
• Support for additional data sources, such as Azure Blob storage.
• Data transformation and data Mashup capabilities by moving M expressions from
Power BI Desktop to a Tabular 1400 model.
• Support for BI tools such as Microsoft Excel enable drill-through to a custom detailed dataset
from an aggregated report.
• Object-level security to secure table and column names in addition to the data within them.
• Enhanced support for ragged hierarchies such as organizational charts and chart of accounts.
To benefit from the new features for models at the 1400 compatibility level, prerequisite is to
download and install SQL Server Data Tools (SSDT) 17.0.
21
08 SSAS SQL SERVER 2017 What’s new (Tabular)
Provider data sources versus Structured data sources
• Provider data sources are referred to as legacy data sources because they are typically used in
1200 and earlier compatibility levels to define the data source details.
• Structured data sources are referred to as modern Power Query/M-based data sources because
they correspond to Power Query/M-based data access functions natively present in Power BI tool.
If you don’t add any new data sources, the User Interface is still consistent with the 1200 experience.
Yet, if you mix provider and structured data sources in a model, the UI switches between modern
experience on the left and the legacy UI on the right, depending on what object type you edit. 22
08 SSAS SQL SERVER 2017 What’s new (Tabular)
Provider data sources versus Structured data sources
• In Tabular 1400 level, by default, SSDT creates structured data sources, and when you right-click a
structured data source in Tabular Model Explorer and select Import New Tables, you launch the
modern Get Data UI.
• Only if a model contains provider data sources already, say due to an upgrade from 1200, SSDT
displays the legacy UI for editing these metadata objects.
• As default behavior helps to provide a consistent user interface and avoids confusion, one can fully
enable the legacy UI to create provider data sources in Tabular 1400 models.
• In the current version of SSDT Tabular, you must configure a DWORD parameter called “Enable
Legacy Import” in the Windows registry. Setting this parameter to 1 enables the legacy UI. Setting it
to zero or removing the parameter disables it again.
• With the legacy UI fully enabled, you can right-click on Data Sources in Tabular Model Explorer
and choose to Import From Data Source (Legacy) or reuse Existing Connections (Legacy).
The Microsoft SQL Server Native Client OLE DB Provider is indeed performing faster than the
Mashup engine. In very large Tabular 1400 models connecting to SQL Server databases, it can
therefore be advantageous to use a provider data source and query partitions. 23
This state of promises is also valid for DirectQuery support for Tabular 1400 according to this article.
08 SSAS SQL SERVER 2017 What’s new (Tabular)
New 1400 model features (Support for drill-through and Detail Rows Expression property)
A much-requested feature for Tabular models is the ability to define a custom row set contributing
to a measure value. Multidimensional models achieve this by using drillthrough and rowset actions.
By default, all the columns in the fact table (here FactInternetSales table) are displayed.
This behavior is often not meaningful for the user because too many columns may be shown.
1400 models introduce Detail Rows Expression property for measures. It allows the modeler to
customize the columns and rows returned to the end user.
With the property defined and the model deployed, the custom row set is returned when the user 24
selects Show Details. It automatically honors the filter context of the cell that was selected.
08 SSAS SQL SERVER 2017 What’s new (Tabular)
New 1400 model features (Object-Level Security for Analysis Services Tabular)
Object-level security is a way to hide and
secure tables and/or columns access from users
Tabular models with previous compatibility levels can be used to model parent-child hierarchies.
Hierarchies with a differing number of levels are referred to as ragged hierarchies.
An example of a ragged hierarchy is displayed above showing an organizational chart.
By default, ragged hierarchies are displayed with blanks for levels below the lowest child.
1400 models introduce the Hide Members property to correct this situation.
Simply set the Hide Members property to Hide blank members.
Once this property set on and the model deployed, a more presentable version of the hierarchy is
displayed.
26
09 Azure Analysis Services (Tabular)
With Azure Analysis Services, a variety of BI client tools are submitting MDX or DAX queries without
knowing if Analysis Service is based on a Tabular or Multidimensional model
Benefits of Tabular model
Business logic is managed with DAX and quick to deliver (more agile than OLAP MDX data model)
Super fast queries due to in-memory cache and query mode either in-memory or Direct Query. 27
09 Azure Analysis Services (Tabular)
One can use Azure Resource Manager (ARM) to create and deploy an Azure Analysis Services
instance in the cloud, and use backup restore to quickly move any existing data models to Azure
Analysis Services and take advantage of the scale, flexibility and management benefits of the cloud.
Scale up, scale down, or pause the service is any time possible (pay only for what you use mode).
With Azure Analysis Services is built for hybrid data, organizations can store data in the cloud, on-
premises or a combination of both, enabling a hybrid solution. No need to move on-premises data 28
to the cloud.
09 Azure Analysis Services (Tabular)
Azure Analysis Services is based on SQL Server 2016/2017 Analysis Services technology. Data can be
accessed on-premises and in the cloud and business users or BI professionals can consume the data
on-mobile devices, on the web and in custom apps.
Use Azure Analysis Services as a common BI Semantic Model and combine data from many places
and apply business rules either for Self-service BI or Corporate BI requirements.
Integrate with IT processes such as deployment & DevOps. That includes the flexibility to develop
29 in
Visual Studio environment and take advantage of VS dedicated Application Lifecycle Management.
09 Azure Analysis Services (Tabular)
Azure Analysis Services main features
Azure Analysis Services provides enterprise-grade data modeling in the cloud. It is a fully managed
platform as a service (PaaS), integrated with Azure data platform service.
With Analysis Services, you can mashup and combine data from multiple sources, define metrics,
and secure your data in a single, trusted semantic data model.
The data model provides an easier and faster way for your users to browse massive amounts of data
with client applications like Power BI, Excel, Reporting Services, third-party, and custom apps.
Azure Analysis Services is compatible with many great features already in SQL Server Analysis
Services Enterprise Edition.
Azure Analysis Services supports tabular models at the 1200 and 1400 compatibility levels.
Partitions, row-level security, bi-directional relationships, and translations are all supported.
In-memory and DirectQuery modes are also supported.
Azure Analysis Services integrates with Azure Active Directory provides secure, role-based access to
your critical data and with Azure Data Factory pipelines by including an activity that loads data into
the model. Azure Automation and Azure Functions can be used for lightweight orchestration of 30
models using custom code. More explanations are provided on following Microsoft article.
09 Azure Analysis Services (Tabular)
Introducing the Azure Analysis Services web designer
This new browser-based experience will allow developers to start creating and managing Azure
Analysis Services (AAS) semantic models quickly and easily.
This initial release includes three major capabilities, model creation, model editing, and doing
queries. The model can be created directly from Azure SQL Database and SQL Data Warehouse, or
imported from Power BI Desktop PBIX files.
When creating from a database, you can chose which tables to include and the tool will create a
Direct Query model to your data source.
Then you can view the model metadata, edit the Tabular Model Scripting Language (TMSL) JSON,
and add measures. There are shortcuts to open a model in Power BI Desktop, Excel, or even open a
Visual Studio project which is created from the model on the fly.
You can also create simple queries against the model to see the data or test out a new measure. 31
More explanations are provided on following Microsoft article.