SlideShare a Scribd company logo
1 of 12
ROLAP PARTITIONING IN
MS SQL SERVER 2016
Proof of concept with change queries, sample DB and VS project
WHAT IS INCLUDED IN THIS PRESENTATION
• .rar file on 6th slide with Visual Studio project and SQL, MDX and XMLA queries to see how MOLAP and
ROLAP partitions work
• .rar has Sample OLTP working database
• .rar contains Steps.txt file with steps how to configure permissions for SSAS service account used by
Cubes to get data and retrieve notification about changes in OLTP
• Dimension partitioning
• Defining slices for cube partitions
2
CONTENT:
1. Theory of partitioning and difference between ROLAP and MOLAP partitions in cube and dimension
2. 2. Use case with part of WWI (World Wide Importers) on SQL Server 2016 and VS 2015 project
3. Conclusion and other sources
3
1. THEORY OF PARTITIONING AND DIFFERENCE BETWEEN ROLAP AND
MOLAP PARTITIONS IN CUBES
• To get fresh data in SSAS MOLAP cube processing is needed
• This could take significant amount of time. Negative impact is a lag in displayed data
• Solution – use ROLAP cube, which retrieves data directly from OLTP database without processing
• ROLAP cube is slower than MOLAP cube because data needs to go from OLTP to SSAS database. See
picture on next slide.
• Partitions in cube could be separated into to MOLAP part and ROLAP part. MOLAP part needs to be
processed go get fresh data while ROLAP part goes directly to OLTP database to get data.
• Such a cube, will take majority of data from MOLAP partition (like all years before) and last year
takes from ROLAP partition. To get desired results, ROLAP have smaller portion of data than
MOLAP.
• Result – Fast cube (slower than pure MOLAP) but with actual data (actual for last year)
4
1. THEORY OF PARTITIONING AND DIFFERENCE BETWEEN ROLAP AND
MOLAP PARTITIONS IN CUBES
5
2. USE CASE WITH PART OF WWI (WORLD WIDE IMPORTERS) ON
SQL SERVER 2016 AND VS 2015 PROJECT
• For demonstration of ROLAP partitioning use sample database in folder Databases +
installation “Steps.txt”
• Be careful about permissions. To make ROLAP cube work is needed to setup correct
permissions for SSAS Service account in OLTP Server with ALTER Trace permission.
Without this, partition in cube will not get notification about changed data and will not
know, that something changed in data.
6
• ROLAP cubes have two partitions, divided according date dimension
• Two cubes “AmountROLAPtableBinding” and “AmountROLAPqueryBinding” have two
partitions for each – one MOLAP (previous years) and one ROLAP (current year)
• Cube “AmountMOLAP” has one MOLAP partition
• See queries in folder /Queries. Run “Measure Change Queries.sql”. There are two inserts
which write new sale of product with today’s date. Last select displays results, which should
give MDX queries.
• MDX queries against ROLAP cubes give the same result as SQL query
• MDX query against MOLAP cube gives the same result after processing database by
running XMLA script in “Process SSAS db.xmla” file.
• Run change query again and see difference
7
2. USE CASE WITH PART OF WWI (WORLD WIDE IMPORTERS) ON
SQL SERVER 2016 AND VS 2015 PROJECT
• Two scenarios exist for splitting data into partitions
a) Table binding – use separate views to get divided data
b) Query binding – use one source and according SQL Query, SSAS divides data into
partitions. A “Where” clause in SQL query is mandatory in this case
• See cube’s “AmountROLAPtableBinding” partitions and their sources. Click on three dots
and will see “Table binding” setup. For cube “AmountROLAPqueryBinding” is option “Query
binding” picked up and appropriate SQL Query is provided.
• See “Slice” property for every partition. There is MDX query, which tells to SSAS engine
which partition to touch to get data.
• Appropriate ROLAP partition is identified in SSAS engine running MDX query and SQL
query goes to OLTP to get data.
• This is not happening automatically – notification about data change needs to come into
SSAS engine. ROLAP mode is kind of MOLAP mode with enabled “Proactive caching” with
zero latency and enabled notifications.
8
2. USE CASE WITH PART OF WWI (WORLD WIDE IMPORTERS) ON
SQL SERVER 2016 AND VS 2015 PROJECT
• If notifications are not setup properly (alter trace permission is not granted to Service
account on Server level and “db_datareader” on DB level) ROLAP partition works as MOLAP
partition
• Last setup for partitions is “Slice” property. Slice provides full control about partitions, which
will be used for MDX queries, and full speed of the source of data. It is officially
recommended as “Good practice” to define slice property for every partition. But, MDX
query in this property has several restrictions.
• We cannot use “Generate” or range “:” to generate data, what restricts significantly MDX
queries to define parts of data.
• List of members could be generated dynamically during object processing by SSIS job.
• In this example I use simple dividing by years and list all years of Time dimension
9
2. USE CASE WITH PART OF WWI (WORLD WIDE IMPORTERS) ON
SQL SERVER 2016 AND VS 2015 PROJECT
• Same steps are needed as for Measure partitioning until one bug in VS.
• Go to dimension properties (not member properties), choose storage mode ROLAP and
proactive caching “Real-time ROLAP”.
• But after successful deployment and processing of DB I get error in DB engine running MDX
query in SSMS. There is one setting in property “Error Configuration”. After changing
dimension mode to ROLAP, VS automatically changes dimension’s “Error Configuration”
property to “Custom”.
• This causes errors during running MDX queries. Change this property “Default” and process.
MDXs should run without error now.
• After this change I changed “Error Configuration” property back to “Custom” and it works
also.
10
2. USE CASE WITH PART OF WWI (WORLD WIDE IMPORTERS) ON
SQL SERVER 2016 AND VS 2015 PROJECT
• To test ROLAP functionality in dimension Customers us second query in file “Dimension
Change Queries.sql”.
• Updates change CustomerID from 83 to 10000 in source database. MDXs use CustomerID =
83, so there will be no result
• This change proves, that dimension “Customers” is in ROLAP mode so change in OLTP
reflects immediately
• Change influences also MOLAP cube, because use the same ROLAP dimension “Customers”
11
2. USE CASE WITH PART OF WWI (WORLD WIDE IMPORTERS) ON
SQL SERVER 2016 AND VS 2015 PROJECT
3. CONCLUSION AND OTHER SOURCES
• Benefits – it is possible to have actual data from not processed cube
• This makes sense for large cubes, where processing take more time
• Cons - changes in OLTP which does not fall in basket of ROLAP partition are not
reflected in these cubes until processing
• See article about how SSAS works with partitions and slice queries:
http://sqljason.com/2012/01/set-slice-on-your-ssas-cube-partitions.html
• See link how to setup SSIS job to generate slice queries during cube
processing https://msdn.microsoft.com/en-us/library/ms174764.aspx
• In case of interest about this area, help with configuration or comments please contact
me via LinkedIn - “Andrej Zafka” or via email andrej.zafka@gmail.com
• Thank you for reading till end
12

More Related Content

What's hot

Stream Processing with Pipelines and Stored Procedures
Stream Processing with Pipelines  and Stored ProceduresStream Processing with Pipelines  and Stored Procedures
Stream Processing with Pipelines and Stored ProceduresSingleStore
 
What to expect from MariaDB Platform X5, part 1
What to expect from MariaDB Platform X5, part 1What to expect from MariaDB Platform X5, part 1
What to expect from MariaDB Platform X5, part 1MariaDB plc
 
Whitepaper Performance Tuning using Upsert and SCD (Task Factory)
Whitepaper  Performance Tuning using Upsert and SCD (Task Factory)Whitepaper  Performance Tuning using Upsert and SCD (Task Factory)
Whitepaper Performance Tuning using Upsert and SCD (Task Factory)MILL5
 
Enteros StarWest 2012 - Database load testing
Enteros StarWest 2012 - Database load testing Enteros StarWest 2012 - Database load testing
Enteros StarWest 2012 - Database load testing ronwarshawsky
 
Why & how to optimize sql server for performance from design to query
Why & how to optimize sql server for performance from design to queryWhy & how to optimize sql server for performance from design to query
Why & how to optimize sql server for performance from design to queryAntonios Chatzipavlis
 
Products.intro.forum version
Products.intro.forum versionProducts.intro.forum version
Products.intro.forum versionsqlserver.co.il
 
How Database Convergence Impacts the Coming Decades of Data Management
How Database Convergence Impacts the Coming Decades of Data ManagementHow Database Convergence Impacts the Coming Decades of Data Management
How Database Convergence Impacts the Coming Decades of Data ManagementSingleStore
 
Optimizing your Database Import!
Optimizing your Database Import! Optimizing your Database Import!
Optimizing your Database Import! Nabil Nawaz
 
Why PostgreSQL for Analytics Infrastructure (DW)?
Why PostgreSQL for Analytics Infrastructure (DW)?Why PostgreSQL for Analytics Infrastructure (DW)?
Why PostgreSQL for Analytics Infrastructure (DW)?Huy Nguyen
 
Oracle 12.2 sharded database management
Oracle 12.2 sharded database managementOracle 12.2 sharded database management
Oracle 12.2 sharded database managementLeyi (Kamus) Zhang
 
Chapter1: NoSQL: It’s about making intelligent choices
Chapter1: NoSQL: It’s about making intelligent choicesChapter1: NoSQL: It’s about making intelligent choices
Chapter1: NoSQL: It’s about making intelligent choicesMaynooth University
 
Under the hood: SkySQL monitoring
Under the hood: SkySQL monitoringUnder the hood: SkySQL monitoring
Under the hood: SkySQL monitoringMariaDB plc
 
Sql server 2012 dba online training
Sql server 2012 dba online trainingSql server 2012 dba online training
Sql server 2012 dba online trainingsqlmasters
 
Image Recognition on Streaming Data
Image Recognition  on Streaming DataImage Recognition  on Streaming Data
Image Recognition on Streaming DataSingleStore
 
Srimanta_Maji_Oracle_DBA
Srimanta_Maji_Oracle_DBASrimanta_Maji_Oracle_DBA
Srimanta_Maji_Oracle_DBASRIMANTA MAJI
 
Connecting Hadoop and Oracle
Connecting Hadoop and OracleConnecting Hadoop and Oracle
Connecting Hadoop and OracleTanel Poder
 
SQL Server 2016 novelties
SQL Server 2016 noveltiesSQL Server 2016 novelties
SQL Server 2016 noveltiesMSDEVMTL
 
An AMIS Overview of Oracle database 12c (12.1)
An AMIS Overview of Oracle database 12c (12.1)An AMIS Overview of Oracle database 12c (12.1)
An AMIS Overview of Oracle database 12c (12.1)Marco Gralike
 

What's hot (20)

Stream Processing with Pipelines and Stored Procedures
Stream Processing with Pipelines  and Stored ProceduresStream Processing with Pipelines  and Stored Procedures
Stream Processing with Pipelines and Stored Procedures
 
What to expect from MariaDB Platform X5, part 1
What to expect from MariaDB Platform X5, part 1What to expect from MariaDB Platform X5, part 1
What to expect from MariaDB Platform X5, part 1
 
Whitepaper Performance Tuning using Upsert and SCD (Task Factory)
Whitepaper  Performance Tuning using Upsert and SCD (Task Factory)Whitepaper  Performance Tuning using Upsert and SCD (Task Factory)
Whitepaper Performance Tuning using Upsert and SCD (Task Factory)
 
Enteros StarWest 2012 - Database load testing
Enteros StarWest 2012 - Database load testing Enteros StarWest 2012 - Database load testing
Enteros StarWest 2012 - Database load testing
 
Why & how to optimize sql server for performance from design to query
Why & how to optimize sql server for performance from design to queryWhy & how to optimize sql server for performance from design to query
Why & how to optimize sql server for performance from design to query
 
Products.intro.forum version
Products.intro.forum versionProducts.intro.forum version
Products.intro.forum version
 
How Database Convergence Impacts the Coming Decades of Data Management
How Database Convergence Impacts the Coming Decades of Data ManagementHow Database Convergence Impacts the Coming Decades of Data Management
How Database Convergence Impacts the Coming Decades of Data Management
 
Optimizing your Database Import!
Optimizing your Database Import! Optimizing your Database Import!
Optimizing your Database Import!
 
Why PostgreSQL for Analytics Infrastructure (DW)?
Why PostgreSQL for Analytics Infrastructure (DW)?Why PostgreSQL for Analytics Infrastructure (DW)?
Why PostgreSQL for Analytics Infrastructure (DW)?
 
Oracle 12.2 sharded database management
Oracle 12.2 sharded database managementOracle 12.2 sharded database management
Oracle 12.2 sharded database management
 
Mysql For Developers
Mysql For DevelopersMysql For Developers
Mysql For Developers
 
Chapter1: NoSQL: It’s about making intelligent choices
Chapter1: NoSQL: It’s about making intelligent choicesChapter1: NoSQL: It’s about making intelligent choices
Chapter1: NoSQL: It’s about making intelligent choices
 
Under the hood: SkySQL monitoring
Under the hood: SkySQL monitoringUnder the hood: SkySQL monitoring
Under the hood: SkySQL monitoring
 
OOW13 Exadata and ODI with Parallel
OOW13 Exadata and ODI with ParallelOOW13 Exadata and ODI with Parallel
OOW13 Exadata and ODI with Parallel
 
Sql server 2012 dba online training
Sql server 2012 dba online trainingSql server 2012 dba online training
Sql server 2012 dba online training
 
Image Recognition on Streaming Data
Image Recognition  on Streaming DataImage Recognition  on Streaming Data
Image Recognition on Streaming Data
 
Srimanta_Maji_Oracle_DBA
Srimanta_Maji_Oracle_DBASrimanta_Maji_Oracle_DBA
Srimanta_Maji_Oracle_DBA
 
Connecting Hadoop and Oracle
Connecting Hadoop and OracleConnecting Hadoop and Oracle
Connecting Hadoop and Oracle
 
SQL Server 2016 novelties
SQL Server 2016 noveltiesSQL Server 2016 novelties
SQL Server 2016 novelties
 
An AMIS Overview of Oracle database 12c (12.1)
An AMIS Overview of Oracle database 12c (12.1)An AMIS Overview of Oracle database 12c (12.1)
An AMIS Overview of Oracle database 12c (12.1)
 

Viewers also liked

Conventions of my magazine question 1
Conventions of my magazine question 1Conventions of my magazine question 1
Conventions of my magazine question 1Charlotte Bowerman
 
陈兵教授《论附佛外道》
陈兵教授《论附佛外道》陈兵教授《论附佛外道》
陈兵教授《论附佛外道》walkmankim
 
10 Chlorine Dioxide Not Chlorine
10 Chlorine Dioxide Not Chlorine10 Chlorine Dioxide Not Chlorine
10 Chlorine Dioxide Not ChlorineEwan Cameron
 
Living in the moment
Living in the momentLiving in the moment
Living in the momentwalkmankim
 
使用 zotero 做文獻管理及引用(1)
使用 zotero 做文獻管理及引用(1)使用 zotero 做文獻管理及引用(1)
使用 zotero 做文獻管理及引用(1)Chengtao Lin
 
Mission vishvas-resume template-109
Mission vishvas-resume template-109Mission vishvas-resume template-109
Mission vishvas-resume template-109vishvas786
 
Skriva för webben - E-business 2.0
Skriva för webben - E-business 2.0Skriva för webben - E-business 2.0
Skriva för webben - E-business 2.0Kajsa Snickars
 
Environmental influences on the eating habits of children
Environmental influences on the eating habits of childrenEnvironmental influences on the eating habits of children
Environmental influences on the eating habits of childrenaleighb801
 
圣严法师《佛教入门》
圣严法师《佛教入门》圣严法师《佛教入门》
圣严法师《佛教入门》walkmankim
 
One indiabulls gurgaon sector 104 indiabulls gurgaon sector 104 dwarka expres...
One indiabulls gurgaon sector 104 indiabulls gurgaon sector 104 dwarka expres...One indiabulls gurgaon sector 104 indiabulls gurgaon sector 104 dwarka expres...
One indiabulls gurgaon sector 104 indiabulls gurgaon sector 104 dwarka expres...sachivchawla
 
DevOps Naughties Style - How We DevOps at MP3.com in the Early 2000's
DevOps Naughties Style - How We  DevOps at MP3.com in the Early 2000'sDevOps Naughties Style - How We  DevOps at MP3.com in the Early 2000's
DevOps Naughties Style - How We DevOps at MP3.com in the Early 2000'stechopsguru
 
Ambience creacions
Ambience creacionsAmbience creacions
Ambience creacionssachivchawla
 
διδω σωτηριου
διδω σωτηριουδιδω σωτηριου
διδω σωτηριουekidrou
 
Copia de christmas (orchard hollow)
Copia de christmas (orchard hollow)Copia de christmas (orchard hollow)
Copia de christmas (orchard hollow)soniapr30
 
Digitization @ The State Library of Arizona
Digitization @ The State Library of ArizonaDigitization @ The State Library of Arizona
Digitization @ The State Library of Arizonastatelibaz
 

Viewers also liked (20)

Conventions of my magazine question 1
Conventions of my magazine question 1Conventions of my magazine question 1
Conventions of my magazine question 1
 
陈兵教授《论附佛外道》
陈兵教授《论附佛外道》陈兵教授《论附佛外道》
陈兵教授《论附佛外道》
 
10 Chlorine Dioxide Not Chlorine
10 Chlorine Dioxide Not Chlorine10 Chlorine Dioxide Not Chlorine
10 Chlorine Dioxide Not Chlorine
 
Living in the moment
Living in the momentLiving in the moment
Living in the moment
 
使用 zotero 做文獻管理及引用(1)
使用 zotero 做文獻管理及引用(1)使用 zotero 做文獻管理及引用(1)
使用 zotero 做文獻管理及引用(1)
 
Mission vishvas-resume template-109
Mission vishvas-resume template-109Mission vishvas-resume template-109
Mission vishvas-resume template-109
 
французська кухня
французська кухняфранцузська кухня
французська кухня
 
Jorge 3
Jorge 3Jorge 3
Jorge 3
 
Skriva för webben - E-business 2.0
Skriva för webben - E-business 2.0Skriva för webben - E-business 2.0
Skriva för webben - E-business 2.0
 
Environmental influences on the eating habits of children
Environmental influences on the eating habits of childrenEnvironmental influences on the eating habits of children
Environmental influences on the eating habits of children
 
圣严法师《佛教入门》
圣严法师《佛教入门》圣严法师《佛教入门》
圣严法师《佛教入门》
 
One indiabulls gurgaon sector 104 indiabulls gurgaon sector 104 dwarka expres...
One indiabulls gurgaon sector 104 indiabulls gurgaon sector 104 dwarka expres...One indiabulls gurgaon sector 104 indiabulls gurgaon sector 104 dwarka expres...
One indiabulls gurgaon sector 104 indiabulls gurgaon sector 104 dwarka expres...
 
DevOps Naughties Style - How We DevOps at MP3.com in the Early 2000's
DevOps Naughties Style - How We  DevOps at MP3.com in the Early 2000'sDevOps Naughties Style - How We  DevOps at MP3.com in the Early 2000's
DevOps Naughties Style - How We DevOps at MP3.com in the Early 2000's
 
Ambience creacions
Ambience creacionsAmbience creacions
Ambience creacions
 
Ancillary production
Ancillary productionAncillary production
Ancillary production
 
διδω σωτηριου
διδω σωτηριουδιδω σωτηριου
διδω σωτηριου
 
Copia de christmas (orchard hollow)
Copia de christmas (orchard hollow)Copia de christmas (orchard hollow)
Copia de christmas (orchard hollow)
 
TOUCH
TOUCHTOUCH
TOUCH
 
Digitization @ The State Library of Arizona
Digitization @ The State Library of ArizonaDigitization @ The State Library of Arizona
Digitization @ The State Library of Arizona
 
Test slideshare
Test slideshareTest slideshare
Test slideshare
 

Similar to ROLAP partitioning in MS SQL Server 2016

Case Study Real Time Olap Cubes
Case Study Real Time Olap CubesCase Study Real Time Olap Cubes
Case Study Real Time Olap Cubesmister_zed
 
86921864 olap-case-study-vj
86921864 olap-case-study-vj86921864 olap-case-study-vj
86921864 olap-case-study-vjhomeworkping4
 
Oracle RAC 12c and Policy-Managed Databases, a Technical Overview
Oracle RAC 12c and Policy-Managed Databases, a Technical OverviewOracle RAC 12c and Policy-Managed Databases, a Technical Overview
Oracle RAC 12c and Policy-Managed Databases, a Technical OverviewLudovico Caldara
 
Sql Server 2005 Business Inteligence
Sql Server 2005 Business InteligenceSql Server 2005 Business Inteligence
Sql Server 2005 Business Inteligenceabercius24
 
Kb 40 kevin_klineukug_reading20070717[1]
Kb 40 kevin_klineukug_reading20070717[1]Kb 40 kevin_klineukug_reading20070717[1]
Kb 40 kevin_klineukug_reading20070717[1]shuwutong
 
OLAP OnLine Analytical Processing
OLAP OnLine Analytical ProcessingOLAP OnLine Analytical Processing
OLAP OnLine Analytical ProcessingWalid Elbadawy
 
OracleStore: A Highly Performant RawStore Implementation for Hive Metastore
OracleStore: A Highly Performant RawStore Implementation for Hive MetastoreOracleStore: A Highly Performant RawStore Implementation for Hive Metastore
OracleStore: A Highly Performant RawStore Implementation for Hive MetastoreDataWorks Summit
 
Sql server-dba
Sql server-dbaSql server-dba
Sql server-dbaNaviSoft
 
QuestDB-Community-Call-20220728
QuestDB-Community-Call-20220728QuestDB-Community-Call-20220728
QuestDB-Community-Call-20220728javier ramirez
 
Aioug vizag oracle12c_new_features
Aioug vizag oracle12c_new_featuresAioug vizag oracle12c_new_features
Aioug vizag oracle12c_new_featuresAiougVizagChapter
 
My sql cluster case study apr16
My sql cluster case study apr16My sql cluster case study apr16
My sql cluster case study apr16Sumi Ryu
 
Sql server introduction fundamental
Sql server introduction fundamentalSql server introduction fundamental
Sql server introduction fundamentalRiteshkiit
 
Harnessing the power of both worlds
Harnessing the power of both worldsHarnessing the power of both worlds
Harnessing the power of both worldsKaran Gulati
 
Stateful streaming and the challenge of state
Stateful streaming and the challenge of stateStateful streaming and the challenge of state
Stateful streaming and the challenge of stateYoni Farin
 
Self-serve analytics journey at Celtra: Snowflake, Spark, and Databricks
Self-serve analytics journey at Celtra: Snowflake, Spark, and DatabricksSelf-serve analytics journey at Celtra: Snowflake, Spark, and Databricks
Self-serve analytics journey at Celtra: Snowflake, Spark, and DatabricksGrega Kespret
 
ScaleBase Webinar: Scaling MySQL - Sharding Made Easy!
ScaleBase Webinar: Scaling MySQL - Sharding Made Easy!ScaleBase Webinar: Scaling MySQL - Sharding Made Easy!
ScaleBase Webinar: Scaling MySQL - Sharding Made Easy!ScaleBase
 
Kafka streams fifth elephant 2018
Kafka streams fifth elephant 2018Kafka streams fifth elephant 2018
Kafka streams fifth elephant 2018Giridhar Addepalli
 

Similar to ROLAP partitioning in MS SQL Server 2016 (20)

Case Study Real Time Olap Cubes
Case Study Real Time Olap CubesCase Study Real Time Olap Cubes
Case Study Real Time Olap Cubes
 
86921864 olap-case-study-vj
86921864 olap-case-study-vj86921864 olap-case-study-vj
86921864 olap-case-study-vj
 
Oracle RAC 12c and Policy-Managed Databases, a Technical Overview
Oracle RAC 12c and Policy-Managed Databases, a Technical OverviewOracle RAC 12c and Policy-Managed Databases, a Technical Overview
Oracle RAC 12c and Policy-Managed Databases, a Technical Overview
 
Sql Server 2005 Business Inteligence
Sql Server 2005 Business InteligenceSql Server 2005 Business Inteligence
Sql Server 2005 Business Inteligence
 
Kb 40 kevin_klineukug_reading20070717[1]
Kb 40 kevin_klineukug_reading20070717[1]Kb 40 kevin_klineukug_reading20070717[1]
Kb 40 kevin_klineukug_reading20070717[1]
 
OLAP OnLine Analytical Processing
OLAP OnLine Analytical ProcessingOLAP OnLine Analytical Processing
OLAP OnLine Analytical Processing
 
What's new in SQL Server Integration Services 2012?
What's new in SQL Server Integration Services 2012?What's new in SQL Server Integration Services 2012?
What's new in SQL Server Integration Services 2012?
 
OracleStore: A Highly Performant RawStore Implementation for Hive Metastore
OracleStore: A Highly Performant RawStore Implementation for Hive MetastoreOracleStore: A Highly Performant RawStore Implementation for Hive Metastore
OracleStore: A Highly Performant RawStore Implementation for Hive Metastore
 
MySQL Cluster
MySQL ClusterMySQL Cluster
MySQL Cluster
 
Sql server-dba
Sql server-dbaSql server-dba
Sql server-dba
 
QuestDB-Community-Call-20220728
QuestDB-Community-Call-20220728QuestDB-Community-Call-20220728
QuestDB-Community-Call-20220728
 
Aioug vizag oracle12c_new_features
Aioug vizag oracle12c_new_featuresAioug vizag oracle12c_new_features
Aioug vizag oracle12c_new_features
 
My sql cluster case study apr16
My sql cluster case study apr16My sql cluster case study apr16
My sql cluster case study apr16
 
Sql server introduction fundamental
Sql server introduction fundamentalSql server introduction fundamental
Sql server introduction fundamental
 
Harnessing the power of both worlds
Harnessing the power of both worldsHarnessing the power of both worlds
Harnessing the power of both worlds
 
Stateful streaming and the challenge of state
Stateful streaming and the challenge of stateStateful streaming and the challenge of state
Stateful streaming and the challenge of state
 
Self-serve analytics journey at Celtra: Snowflake, Spark, and Databricks
Self-serve analytics journey at Celtra: Snowflake, Spark, and DatabricksSelf-serve analytics journey at Celtra: Snowflake, Spark, and Databricks
Self-serve analytics journey at Celtra: Snowflake, Spark, and Databricks
 
An AMIS overview of database 12c
An AMIS overview of database 12cAn AMIS overview of database 12c
An AMIS overview of database 12c
 
ScaleBase Webinar: Scaling MySQL - Sharding Made Easy!
ScaleBase Webinar: Scaling MySQL - Sharding Made Easy!ScaleBase Webinar: Scaling MySQL - Sharding Made Easy!
ScaleBase Webinar: Scaling MySQL - Sharding Made Easy!
 
Kafka streams fifth elephant 2018
Kafka streams fifth elephant 2018Kafka streams fifth elephant 2018
Kafka streams fifth elephant 2018
 

Recently uploaded

04242024_CCC TUG_Joins and Relationships
04242024_CCC TUG_Joins and Relationships04242024_CCC TUG_Joins and Relationships
04242024_CCC TUG_Joins and Relationshipsccctableauusergroup
 
Digi Khata Problem along complete plan.pptx
Digi Khata Problem along complete plan.pptxDigi Khata Problem along complete plan.pptx
Digi Khata Problem along complete plan.pptxTanveerAhmed817946
 
EMERCE - 2024 - AMSTERDAM - CROSS-PLATFORM TRACKING WITH GOOGLE ANALYTICS.pptx
EMERCE - 2024 - AMSTERDAM - CROSS-PLATFORM  TRACKING WITH GOOGLE ANALYTICS.pptxEMERCE - 2024 - AMSTERDAM - CROSS-PLATFORM  TRACKING WITH GOOGLE ANALYTICS.pptx
EMERCE - 2024 - AMSTERDAM - CROSS-PLATFORM TRACKING WITH GOOGLE ANALYTICS.pptxthyngster
 
Low Rate Call Girls Bhilai Anika 8250192130 Independent Escort Service Bhilai
Low Rate Call Girls Bhilai Anika 8250192130 Independent Escort Service BhilaiLow Rate Call Girls Bhilai Anika 8250192130 Independent Escort Service Bhilai
Low Rate Call Girls Bhilai Anika 8250192130 Independent Escort Service BhilaiSuhani Kapoor
 
PKS-TGC-1084-630 - Stage 1 Proposal.pptx
PKS-TGC-1084-630 - Stage 1 Proposal.pptxPKS-TGC-1084-630 - Stage 1 Proposal.pptx
PKS-TGC-1084-630 - Stage 1 Proposal.pptxPramod Kumar Srivastava
 
Aminabad Call Girl Agent 9548273370 , Call Girls Service Lucknow
Aminabad Call Girl Agent 9548273370 , Call Girls Service LucknowAminabad Call Girl Agent 9548273370 , Call Girls Service Lucknow
Aminabad Call Girl Agent 9548273370 , Call Girls Service Lucknowmakika9823
 
Industrialised data - the key to AI success.pdf
Industrialised data - the key to AI success.pdfIndustrialised data - the key to AI success.pdf
Industrialised data - the key to AI success.pdfLars Albertsson
 
VIP Call Girls Service Miyapur Hyderabad Call +91-8250192130
VIP Call Girls Service Miyapur Hyderabad Call +91-8250192130VIP Call Girls Service Miyapur Hyderabad Call +91-8250192130
VIP Call Girls Service Miyapur Hyderabad Call +91-8250192130Suhani Kapoor
 
Call Girls In Mahipalpur O9654467111 Escorts Service
Call Girls In Mahipalpur O9654467111  Escorts ServiceCall Girls In Mahipalpur O9654467111  Escorts Service
Call Girls In Mahipalpur O9654467111 Escorts ServiceSapana Sha
 
Market Analysis in the 5 Largest Economic Countries in Southeast Asia.pdf
Market Analysis in the 5 Largest Economic Countries in Southeast Asia.pdfMarket Analysis in the 5 Largest Economic Countries in Southeast Asia.pdf
Market Analysis in the 5 Largest Economic Countries in Southeast Asia.pdfRachmat Ramadhan H
 
{Pooja: 9892124323 } Call Girl in Mumbai | Jas Kaur Rate 4500 Free Hotel Del...
{Pooja:  9892124323 } Call Girl in Mumbai | Jas Kaur Rate 4500 Free Hotel Del...{Pooja:  9892124323 } Call Girl in Mumbai | Jas Kaur Rate 4500 Free Hotel Del...
{Pooja: 9892124323 } Call Girl in Mumbai | Jas Kaur Rate 4500 Free Hotel Del...Pooja Nehwal
 
Call Girls in Defence Colony Delhi 💯Call Us 🔝8264348440🔝
Call Girls in Defence Colony Delhi 💯Call Us 🔝8264348440🔝Call Girls in Defence Colony Delhi 💯Call Us 🔝8264348440🔝
Call Girls in Defence Colony Delhi 💯Call Us 🔝8264348440🔝soniya singh
 
Schema on read is obsolete. Welcome metaprogramming..pdf
Schema on read is obsolete. Welcome metaprogramming..pdfSchema on read is obsolete. Welcome metaprogramming..pdf
Schema on read is obsolete. Welcome metaprogramming..pdfLars Albertsson
 
From idea to production in a day – Leveraging Azure ML and Streamlit to build...
From idea to production in a day – Leveraging Azure ML and Streamlit to build...From idea to production in a day – Leveraging Azure ML and Streamlit to build...
From idea to production in a day – Leveraging Azure ML and Streamlit to build...Florian Roscheck
 
Customer Service Analytics - Make Sense of All Your Data.pptx
Customer Service Analytics - Make Sense of All Your Data.pptxCustomer Service Analytics - Make Sense of All Your Data.pptx
Customer Service Analytics - Make Sense of All Your Data.pptxEmmanuel Dauda
 
Full night 🥵 Call Girls Delhi New Friends Colony {9711199171} Sanya Reddy ✌️o...
Full night 🥵 Call Girls Delhi New Friends Colony {9711199171} Sanya Reddy ✌️o...Full night 🥵 Call Girls Delhi New Friends Colony {9711199171} Sanya Reddy ✌️o...
Full night 🥵 Call Girls Delhi New Friends Colony {9711199171} Sanya Reddy ✌️o...shivangimorya083
 
B2 Creative Industry Response Evaluation.docx
B2 Creative Industry Response Evaluation.docxB2 Creative Industry Response Evaluation.docx
B2 Creative Industry Response Evaluation.docxStephen266013
 
Delhi Call Girls CP 9711199171 ☎✔👌✔ Whatsapp Hard And Sexy Vip Call
Delhi Call Girls CP 9711199171 ☎✔👌✔ Whatsapp Hard And Sexy Vip CallDelhi Call Girls CP 9711199171 ☎✔👌✔ Whatsapp Hard And Sexy Vip Call
Delhi Call Girls CP 9711199171 ☎✔👌✔ Whatsapp Hard And Sexy Vip Callshivangimorya083
 
VIP High Class Call Girls Jamshedpur Anushka 8250192130 Independent Escort Se...
VIP High Class Call Girls Jamshedpur Anushka 8250192130 Independent Escort Se...VIP High Class Call Girls Jamshedpur Anushka 8250192130 Independent Escort Se...
VIP High Class Call Girls Jamshedpur Anushka 8250192130 Independent Escort Se...Suhani Kapoor
 

Recently uploaded (20)

04242024_CCC TUG_Joins and Relationships
04242024_CCC TUG_Joins and Relationships04242024_CCC TUG_Joins and Relationships
04242024_CCC TUG_Joins and Relationships
 
Digi Khata Problem along complete plan.pptx
Digi Khata Problem along complete plan.pptxDigi Khata Problem along complete plan.pptx
Digi Khata Problem along complete plan.pptx
 
EMERCE - 2024 - AMSTERDAM - CROSS-PLATFORM TRACKING WITH GOOGLE ANALYTICS.pptx
EMERCE - 2024 - AMSTERDAM - CROSS-PLATFORM  TRACKING WITH GOOGLE ANALYTICS.pptxEMERCE - 2024 - AMSTERDAM - CROSS-PLATFORM  TRACKING WITH GOOGLE ANALYTICS.pptx
EMERCE - 2024 - AMSTERDAM - CROSS-PLATFORM TRACKING WITH GOOGLE ANALYTICS.pptx
 
Low Rate Call Girls Bhilai Anika 8250192130 Independent Escort Service Bhilai
Low Rate Call Girls Bhilai Anika 8250192130 Independent Escort Service BhilaiLow Rate Call Girls Bhilai Anika 8250192130 Independent Escort Service Bhilai
Low Rate Call Girls Bhilai Anika 8250192130 Independent Escort Service Bhilai
 
PKS-TGC-1084-630 - Stage 1 Proposal.pptx
PKS-TGC-1084-630 - Stage 1 Proposal.pptxPKS-TGC-1084-630 - Stage 1 Proposal.pptx
PKS-TGC-1084-630 - Stage 1 Proposal.pptx
 
Aminabad Call Girl Agent 9548273370 , Call Girls Service Lucknow
Aminabad Call Girl Agent 9548273370 , Call Girls Service LucknowAminabad Call Girl Agent 9548273370 , Call Girls Service Lucknow
Aminabad Call Girl Agent 9548273370 , Call Girls Service Lucknow
 
Industrialised data - the key to AI success.pdf
Industrialised data - the key to AI success.pdfIndustrialised data - the key to AI success.pdf
Industrialised data - the key to AI success.pdf
 
VIP Call Girls Service Miyapur Hyderabad Call +91-8250192130
VIP Call Girls Service Miyapur Hyderabad Call +91-8250192130VIP Call Girls Service Miyapur Hyderabad Call +91-8250192130
VIP Call Girls Service Miyapur Hyderabad Call +91-8250192130
 
Call Girls In Mahipalpur O9654467111 Escorts Service
Call Girls In Mahipalpur O9654467111  Escorts ServiceCall Girls In Mahipalpur O9654467111  Escorts Service
Call Girls In Mahipalpur O9654467111 Escorts Service
 
Market Analysis in the 5 Largest Economic Countries in Southeast Asia.pdf
Market Analysis in the 5 Largest Economic Countries in Southeast Asia.pdfMarket Analysis in the 5 Largest Economic Countries in Southeast Asia.pdf
Market Analysis in the 5 Largest Economic Countries in Southeast Asia.pdf
 
{Pooja: 9892124323 } Call Girl in Mumbai | Jas Kaur Rate 4500 Free Hotel Del...
{Pooja:  9892124323 } Call Girl in Mumbai | Jas Kaur Rate 4500 Free Hotel Del...{Pooja:  9892124323 } Call Girl in Mumbai | Jas Kaur Rate 4500 Free Hotel Del...
{Pooja: 9892124323 } Call Girl in Mumbai | Jas Kaur Rate 4500 Free Hotel Del...
 
VIP Call Girls Service Charbagh { Lucknow Call Girls Service 9548273370 } Boo...
VIP Call Girls Service Charbagh { Lucknow Call Girls Service 9548273370 } Boo...VIP Call Girls Service Charbagh { Lucknow Call Girls Service 9548273370 } Boo...
VIP Call Girls Service Charbagh { Lucknow Call Girls Service 9548273370 } Boo...
 
Call Girls in Defence Colony Delhi 💯Call Us 🔝8264348440🔝
Call Girls in Defence Colony Delhi 💯Call Us 🔝8264348440🔝Call Girls in Defence Colony Delhi 💯Call Us 🔝8264348440🔝
Call Girls in Defence Colony Delhi 💯Call Us 🔝8264348440🔝
 
Schema on read is obsolete. Welcome metaprogramming..pdf
Schema on read is obsolete. Welcome metaprogramming..pdfSchema on read is obsolete. Welcome metaprogramming..pdf
Schema on read is obsolete. Welcome metaprogramming..pdf
 
From idea to production in a day – Leveraging Azure ML and Streamlit to build...
From idea to production in a day – Leveraging Azure ML and Streamlit to build...From idea to production in a day – Leveraging Azure ML and Streamlit to build...
From idea to production in a day – Leveraging Azure ML and Streamlit to build...
 
Customer Service Analytics - Make Sense of All Your Data.pptx
Customer Service Analytics - Make Sense of All Your Data.pptxCustomer Service Analytics - Make Sense of All Your Data.pptx
Customer Service Analytics - Make Sense of All Your Data.pptx
 
Full night 🥵 Call Girls Delhi New Friends Colony {9711199171} Sanya Reddy ✌️o...
Full night 🥵 Call Girls Delhi New Friends Colony {9711199171} Sanya Reddy ✌️o...Full night 🥵 Call Girls Delhi New Friends Colony {9711199171} Sanya Reddy ✌️o...
Full night 🥵 Call Girls Delhi New Friends Colony {9711199171} Sanya Reddy ✌️o...
 
B2 Creative Industry Response Evaluation.docx
B2 Creative Industry Response Evaluation.docxB2 Creative Industry Response Evaluation.docx
B2 Creative Industry Response Evaluation.docx
 
Delhi Call Girls CP 9711199171 ☎✔👌✔ Whatsapp Hard And Sexy Vip Call
Delhi Call Girls CP 9711199171 ☎✔👌✔ Whatsapp Hard And Sexy Vip CallDelhi Call Girls CP 9711199171 ☎✔👌✔ Whatsapp Hard And Sexy Vip Call
Delhi Call Girls CP 9711199171 ☎✔👌✔ Whatsapp Hard And Sexy Vip Call
 
VIP High Class Call Girls Jamshedpur Anushka 8250192130 Independent Escort Se...
VIP High Class Call Girls Jamshedpur Anushka 8250192130 Independent Escort Se...VIP High Class Call Girls Jamshedpur Anushka 8250192130 Independent Escort Se...
VIP High Class Call Girls Jamshedpur Anushka 8250192130 Independent Escort Se...
 

ROLAP partitioning in MS SQL Server 2016

  • 1. ROLAP PARTITIONING IN MS SQL SERVER 2016 Proof of concept with change queries, sample DB and VS project
  • 2. WHAT IS INCLUDED IN THIS PRESENTATION • .rar file on 6th slide with Visual Studio project and SQL, MDX and XMLA queries to see how MOLAP and ROLAP partitions work • .rar has Sample OLTP working database • .rar contains Steps.txt file with steps how to configure permissions for SSAS service account used by Cubes to get data and retrieve notification about changes in OLTP • Dimension partitioning • Defining slices for cube partitions 2
  • 3. CONTENT: 1. Theory of partitioning and difference between ROLAP and MOLAP partitions in cube and dimension 2. 2. Use case with part of WWI (World Wide Importers) on SQL Server 2016 and VS 2015 project 3. Conclusion and other sources 3
  • 4. 1. THEORY OF PARTITIONING AND DIFFERENCE BETWEEN ROLAP AND MOLAP PARTITIONS IN CUBES • To get fresh data in SSAS MOLAP cube processing is needed • This could take significant amount of time. Negative impact is a lag in displayed data • Solution – use ROLAP cube, which retrieves data directly from OLTP database without processing • ROLAP cube is slower than MOLAP cube because data needs to go from OLTP to SSAS database. See picture on next slide. • Partitions in cube could be separated into to MOLAP part and ROLAP part. MOLAP part needs to be processed go get fresh data while ROLAP part goes directly to OLTP database to get data. • Such a cube, will take majority of data from MOLAP partition (like all years before) and last year takes from ROLAP partition. To get desired results, ROLAP have smaller portion of data than MOLAP. • Result – Fast cube (slower than pure MOLAP) but with actual data (actual for last year) 4
  • 5. 1. THEORY OF PARTITIONING AND DIFFERENCE BETWEEN ROLAP AND MOLAP PARTITIONS IN CUBES 5
  • 6. 2. USE CASE WITH PART OF WWI (WORLD WIDE IMPORTERS) ON SQL SERVER 2016 AND VS 2015 PROJECT • For demonstration of ROLAP partitioning use sample database in folder Databases + installation “Steps.txt” • Be careful about permissions. To make ROLAP cube work is needed to setup correct permissions for SSAS Service account in OLTP Server with ALTER Trace permission. Without this, partition in cube will not get notification about changed data and will not know, that something changed in data. 6
  • 7. • ROLAP cubes have two partitions, divided according date dimension • Two cubes “AmountROLAPtableBinding” and “AmountROLAPqueryBinding” have two partitions for each – one MOLAP (previous years) and one ROLAP (current year) • Cube “AmountMOLAP” has one MOLAP partition • See queries in folder /Queries. Run “Measure Change Queries.sql”. There are two inserts which write new sale of product with today’s date. Last select displays results, which should give MDX queries. • MDX queries against ROLAP cubes give the same result as SQL query • MDX query against MOLAP cube gives the same result after processing database by running XMLA script in “Process SSAS db.xmla” file. • Run change query again and see difference 7 2. USE CASE WITH PART OF WWI (WORLD WIDE IMPORTERS) ON SQL SERVER 2016 AND VS 2015 PROJECT
  • 8. • Two scenarios exist for splitting data into partitions a) Table binding – use separate views to get divided data b) Query binding – use one source and according SQL Query, SSAS divides data into partitions. A “Where” clause in SQL query is mandatory in this case • See cube’s “AmountROLAPtableBinding” partitions and their sources. Click on three dots and will see “Table binding” setup. For cube “AmountROLAPqueryBinding” is option “Query binding” picked up and appropriate SQL Query is provided. • See “Slice” property for every partition. There is MDX query, which tells to SSAS engine which partition to touch to get data. • Appropriate ROLAP partition is identified in SSAS engine running MDX query and SQL query goes to OLTP to get data. • This is not happening automatically – notification about data change needs to come into SSAS engine. ROLAP mode is kind of MOLAP mode with enabled “Proactive caching” with zero latency and enabled notifications. 8 2. USE CASE WITH PART OF WWI (WORLD WIDE IMPORTERS) ON SQL SERVER 2016 AND VS 2015 PROJECT
  • 9. • If notifications are not setup properly (alter trace permission is not granted to Service account on Server level and “db_datareader” on DB level) ROLAP partition works as MOLAP partition • Last setup for partitions is “Slice” property. Slice provides full control about partitions, which will be used for MDX queries, and full speed of the source of data. It is officially recommended as “Good practice” to define slice property for every partition. But, MDX query in this property has several restrictions. • We cannot use “Generate” or range “:” to generate data, what restricts significantly MDX queries to define parts of data. • List of members could be generated dynamically during object processing by SSIS job. • In this example I use simple dividing by years and list all years of Time dimension 9 2. USE CASE WITH PART OF WWI (WORLD WIDE IMPORTERS) ON SQL SERVER 2016 AND VS 2015 PROJECT
  • 10. • Same steps are needed as for Measure partitioning until one bug in VS. • Go to dimension properties (not member properties), choose storage mode ROLAP and proactive caching “Real-time ROLAP”. • But after successful deployment and processing of DB I get error in DB engine running MDX query in SSMS. There is one setting in property “Error Configuration”. After changing dimension mode to ROLAP, VS automatically changes dimension’s “Error Configuration” property to “Custom”. • This causes errors during running MDX queries. Change this property “Default” and process. MDXs should run without error now. • After this change I changed “Error Configuration” property back to “Custom” and it works also. 10 2. USE CASE WITH PART OF WWI (WORLD WIDE IMPORTERS) ON SQL SERVER 2016 AND VS 2015 PROJECT
  • 11. • To test ROLAP functionality in dimension Customers us second query in file “Dimension Change Queries.sql”. • Updates change CustomerID from 83 to 10000 in source database. MDXs use CustomerID = 83, so there will be no result • This change proves, that dimension “Customers” is in ROLAP mode so change in OLTP reflects immediately • Change influences also MOLAP cube, because use the same ROLAP dimension “Customers” 11 2. USE CASE WITH PART OF WWI (WORLD WIDE IMPORTERS) ON SQL SERVER 2016 AND VS 2015 PROJECT
  • 12. 3. CONCLUSION AND OTHER SOURCES • Benefits – it is possible to have actual data from not processed cube • This makes sense for large cubes, where processing take more time • Cons - changes in OLTP which does not fall in basket of ROLAP partition are not reflected in these cubes until processing • See article about how SSAS works with partitions and slice queries: http://sqljason.com/2012/01/set-slice-on-your-ssas-cube-partitions.html • See link how to setup SSIS job to generate slice queries during cube processing https://msdn.microsoft.com/en-us/library/ms174764.aspx • In case of interest about this area, help with configuration or comments please contact me via LinkedIn - “Andrej Zafka” or via email andrej.zafka@gmail.com • Thank you for reading till end 12