Presentation is loading. Please wait.

Presentation is loading. Please wait.

Blazing-Fast Performance:

Similar presentations


Presentation on theme: "Blazing-Fast Performance:"— Presentation transcript:

1 Blazing-Fast Performance:
A Technical Best Practices Tour with ColumnStore Index Susan Price Senior Program Manager

2 Is this your data warehouse experience?
Waiting ….

3 Columnstore indexes Waiting ….

4 Agenda Benefits Demo Overview How to use ColumnStore Indexes
Batch mode query execution How to use ColumnStore Indexes Experiences with customer data Best practices

5 BenEfits of columnstore indexes
Faster, interactive query response time Easier data exploration Better decision Reduced physical DB design effort Fewer indexes Reduced need for summary aggregates and indexed views May eliminate need for OLAP cubes Transparent to the application Less hardware needed for given workload

6 Demo

7 What is a columnstore index?
C1 C2 C3 C4 Stores data column-wise Each page stores data from a single column Highly compressed About 2x better than PAGE compression More data fits in memory Each column can be accessed independently Fetch only needed columns Can dramatically reduce IO

8 Batch Mode Query Execution
But Wait, there’s more Would you rather process your data like this … Batch Mode Query Execution Vector-oriented processing Compact data representation Highly efficient algorithms Better parallelism … or like this?

9 Easy to use No need to rewrite application
Create a ColumnStore Index after you create and load the table CREATE NONCLUSTERED COLUMNSTORE INDEX ncci ON myTable(OrderDate, ProductID, SaleAmount) The optimizer makes a cost-based decision When to use the ColumnStore Index When to use batch mode processing Memory management is automatic New object cache for ColumnStore structures New memory broker manages memory allocation Best performance when data is in memory Data not required to fit in memory Options for loading data Use partition switching Build ColumnStore Index on staging table Disable ColumnStore Index, load data, rebuild index

10 Observed compression ratios
Data Set Uncompressed Table Size (MB) ColumnStore Index Size Compression Ratio Cosmetics 1,302 88.5 14.7 SQL 1,431 166 8.6 Xbox 1,045 202 5.2 MS Sales 642,000 126,000 5.1 Web Analytics 2,560 553 4.6 Telecom 2,905 727 4.0 1.8X better compression than SQL Server PAGE compression

11 real customer experiences
Customer Type Industry segment/ Application Measure Without ColumnStore Index (sec) With ColumnStore Index Improvement External Online services Query 1020 3 340x Retail 1080 63 17.1x Healthcare Set of 6 Queries 73894 12782 5.8x Internal HR reporting Avg. response time on production system 220 66 3.3x Financial reporting 3 Queries Each > 50x Queries taking longer than 10 min 90% reduction

12 Best Practices: When to build a Columnstore index
Workload Read-mostly Mostly append new data Star join queries Queries to scan and aggregate large data volumes Workflow Permits partitioning (or disable/rebuild) to handle new data Typically a nightly load window Data selection Build ColumnStore Indexes on large fact tables Consider ColumnStore Indexes for large dimension tables

13 Best Practices: building a Columnstore index
Include all columns in the columnstore index Don’t use to seek into the row Order of listed columns not important Convert decimal/numeric to precision <= 18 If possible Use integer types when possible More compact representation More opportunity for early filtering Ensure sufficient memory to build the columnstore index Create the columnstore index from a clustered index Better segment elimination if filter is on a key column

14 Best Practices: Writing queries
Consider modifying queries to hit “sweet spot” Star joins Inner joins Aggregations Keep statistics up to date Remember that ColumnStore Index is not sorted Consider using hints if needed Pay attention to fundamentals No Magic Bullet Query performance still affected by Schema design Query design Cardinality estimates

15 Columnstore indexes in a nutshell
ColumnStore technology + Advanced query processing Astonishing speedup for DW queries Great compression

16 Thank You! ColumnStore Indexes white paper
Resources ColumnStore Indexes white paper ColumnStore Index FAQs (search for technet columnstore) ColumnStore Index Blog (with link to YouTube video) YouTube videos

17 Further. Forward. Faster.
Learn more Visit the Microsoft Virtual Academy Free technical SQL Server training courses Get more Download SQL Server 2012 Trial Software 180-day evaluation of SQL Server 2012 Do more Participate in virtual launch activities and collect points for prizes The more points you earn, the bigger your prize could be

18


Download ppt "Blazing-Fast Performance:"

Similar presentations


Ads by Google