Successfully reported this slideshow.
We use your LinkedIn profile and activity data to personalize ads and to show you more relevant ads. You can change your ad preferences anytime.

BI With X Velocity

3,219 views

Published on

With SQL Server 2012, Microsoft has introduced the next generation of the VertiPaq engine, xVelocity. xVelocity contains the first two members of Microsoft’s family of in-memory and memory-optimized data management technologies. These members, the in-memory analytics engine and the memory-optimized columnstore index are designed to achieve breakthrough performance for analytic queries.

Curtis Smith is a Principle Lead Consultant based in Atlanta GA. Curtis has been working with SQL Server technologies for over 18 years. His experience includes full life-cycle application development, database architecture, BI reporting and analytics. Curtis is a former Director of Software Development for a major home health agency.

  • Be the first to comment

BI With X Velocity

  1. 1. BI with xVelocityxVelocity In Memory AnalyticsCurtis SmithPrincipal Lead Consultant, Southern RegionMagenic Technologies
  2. 2. xVelocity - Agenda• What is xVelocity• What do expect when using xVelocity.• What makes xVelocity fast? – Columnstore• Demo of creating a Columnstore Index• Take a look at Pivot View Reports
  3. 3. xVelocity – History.• xVelocity In-Memory Analytics Engine –referenced as xVelocity by Microsoft.• xVelocity replaces the VertiPaq engine. – What is VertiPaq? • Used with PowerPoint, best thought of a local analysis services.
  4. 4. xVelocity – How do I get it?• Installed with SQL 2012 Analysis Services.• Installed / enabled with tabular mode. – Not available with Analysis Services Multidimensional. • Again, you must chose tabular mode as Multidimensional is the default.
  5. 5. xVelocity – What can I expect?• Microsoft has tested performance improvements ranging from 10 - 100x.• Get data to your users faster.• Use existing hardware, with exceptions. – More preformat hardware will yield better performance. – Very memory dependent.
  6. 6. xVelocity – What makes it fast?• Analysis is done in memory.• Uses the Columnstore technology. – Columnstore? What’s a Columnstore?• Advanced query execution technology processes chunks of columns in batches.• Makes the largest impact on tables with millions/billions of rows.
  7. 7. xVelocity - Columnstore• Columnstore index is a new type of index• Data is stored differently from traditional indexes – Columnstore stored all columns together on the same page – Traditional indexes Data Value1 Data Value2 Data Value3 DataValue4 Data Value1 Data Value2 Data Value3 DataValue4 Data Value1 Data Value2 Data Value3 DataValue4
  8. 8. xVelocity - Columnstore• Columnstore index Data Value1 Data Value2 Data Value3 Data Value4 Data Value1 Data Value2 Data Value3 Data Value4 Data Value1 Data Value2 Data Value3 Data Value4 Data Value1 Data Value2 Data Value3 Data Value4• Only needed columns are read from disk• Data is typically compressed with better ratio – Provides better hit ratio with cached data
  9. 9. xVelocity – Columnstore continued…• Created using the “COLUMNSTORE” keyword – CREATE COLUMNSTORE INDEX IndexName on TableName• Normally created using all columns of supported type for Columnstore• Query Optimizer choose when to use the column store index• Tables become READ-ONLY, however there are methods of updating tables that have utilize Columnstore indexing – Drop the index and rebuild after inserting the data – Switch the partition
  10. 10. xVelocity – Columnstore continued…• Only one Columnstore index per table• Columnstore indexes on partitioned tables must be partition-aligned.• Building of Columnstore indexes, may require longer to build.• Must be non-clustered• More information may be found at: • SQL Server Columnstore Index FAQ: http://social.technet.microsoft.com/wiki/contents/articles/3540.sql-server- columnstore-index-faq-en-us.aspx
  11. 11. xVelocity - Demo• Create ColumnStore index• Execution mode row vs. batch – Test table with approximately 10 million rows• Update of column store table
  12. 12. xVelocity – Where can I find more?• MSDN: – xVelocity in SQL Server 2012 • http://msdn.microsoft.com/en-us/library/hh922900.aspx – Columnstore Indexes • http://msdn.microsoft.com/en-us/library/gg492088.aspx#Described
  13. 13. xVelocity – more info continued …• SQLBI.com has a very good comparison between VertiPaq and Columnstore – http://www.sqlbi.com/wp-content/uploads/Vertipaq-vs- ColumnStore1.pdf• Microsoft-led benchmark testing datasheet: – http://download.microsoft.com/download/7/2/E/72E63D2D-9F73- 42BB-890F- C1CA0931511C/SQL_Server_2012_xVelocityBenchmark_DatasheetMa r2012.pdf
  14. 14. xVelocity – more info continued• SQL Server Columnstore Index FAQ – http://social.technet.microsoft.com/wiki/contents/articles/3540.sql- server-columnstore-index-faq-en-us.aspx• SQL Server 2012 Columnstore Index In Depth Part 1: Make a bigger AdventureworksDW database for Testing – Steven Wang – http://www.msbicoe.com/post/2012/04/12/xVelocity-Memory- Optimized-Columnstore-index-In-Depth-Part-1-Make-a-bigger- AdventureworksDW-database-for-Testing.aspx
  15. 15. xVelocity – more info continued• SQL Server 2012 Columnstore Index In Depth Part 2: Columnstore Index Physical Data and Size Calculation - Steven Wang – http://www.msbicoe.com/post/2012/04/20/SQL-Server-2012- Columnstore-Index-In-Depth-Part-2-Columnstore-Index-Size- Calculation.aspx
  16. 16. xVelocity – Online Demo(s)• http://blogs.msdn.com/b/oneclickbi/archive/2011/12/27/more-demos- of-power-view-available.aspx
  17. 17. xVelocity – Speaker info• Curtis Smith – Principal Lead Consultant, Southern Region, Magenic • Working with SQL Server technologies for over 18 years. • Full life-cycle application development, database architecture, BI reporting. • Former Director of Software Development for a major home health agency. – Curtiss@magenic.com• http://www.magenic.com• Questions?
  18. 18. xVelocity – Example(s) Create COLUMNSTORE INDEX• /* *************************************************** */• -- create a temp table to demo updating of table with column store index.• /* *************************************************** */• if( OBJECT_ID(SomeTable) IS NOT NULL )• drop table SomeTable• go• create table SomeTable• (• StateAbbrchar(2)not null• PRIMARY KEY CLUSTERED• , StateNamevarchar(30)not null• , ANotevarchar(100)null• )• go• /* *************************************************** */• -- insert some test data• /* *************************************************** */• insert into SomeTable( StateAbbr, StateName ) VALUES ( GA, Georgia )• insert into SomeTable( StateAbbr, StateName ) VALUES ( MN, Minnesota )• /* *************************************************** */• -- update the table, this is allowed• /* *************************************************** */• UPDATE SomeTable SET• ANote = I thought it would be cold.• where StateAbbr = MN
  19. 19. xVelocity – Examples (1) Create COLUMNSTORE INDEX continued …• select * from SomeTable• -- create columnstore index• CREATE NONCLUSTERED COLUMNSTORE INDEX [NonClusteredColumnStoreIndex-TEST] ON [dbo].[SomeTable]• (• [StateAbbr],• [StateName],• [ANote]• )WITH (DROP_EXISTING = OFF) ON [PRIMARY]• -- try to update again• -- this is not allowed, while the table has an active columnstore index• UPDATE SomeTable SET• ANote = The weather was nice.• where StateAbbr = MN• select * from SomeTable• -- disable the index• ALTER INDEX [NonClusteredColumnStoreIndex-TEST] ON [dbo].[SomeTable] DISABLE• GO• -- reenable the index• ALTER INDEX [NonClusteredColumnStoreIndex-TEST] ON [dbo].[SomeTable] REBUILD• GO

×