Oracle Partitioning – Yesterday, Today, and Tomorrow Ananth Raghavan Senior Development Manager, Oracle Partitioning.

Slides:



Advertisements
Similar presentations
Copyright © 2013, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 12 of the corporate.
Advertisements

1 Copyright © 2011, Oracle and/or its affiliates. All rights reserved.
©Silberschatz, Korth and Sudarshan12.1Database System Concepts Chapter 12: Part C Part A:  Index Definition in SQL  Ordered Indices  Index Sequential.
Oracle Universal Content Management and Storage Systems
Copyright © 2014 Oracle and/or its affiliates. All rights reserved. | Oracle SQL Developer Tips & Tricks Jeff Smith
Manuel Neyra Senior Manager EnterpriseOne Product Strategy
1 Copyright © 2011, Oracle and/or its affiliates. All rights reserved.
IS 4420 Database Fundamentals Chapter 6: Physical Database Design and Performance Leon Chen.
Copyright © 2014 Oracle and/or its affiliates. All rights reserved. | Oracle SQL Developer What’s New in Version 4.1 Jeff Smith
Copyright © 2014, Oracle and/or its affiliates. All rights reserved. | Advanced Metadata Modeling Modeling for the Oracle Business Intelligence Cloud.
Copyright © 2014 Oracle and/or its affiliates. All rights reserved. | 2 Hidden Gems of APEX David Gale Software Engineer Oracle Application Express November,
5 Creating the Physical Model. Designing the Physical Model Phase IV: Defining the physical model.
Copyright © 2013, Oracle and/or its affiliates. All rights reserved. 1 Preview of Oracle Database 12 c In-Memory Option Thomas Kyte
Oracle Partitioning in Oracle Database 11g
1  MyOnlineITCourses.com 1 MyOnlineITCourses.com Oracle Partitioning -- A Primer.
Enterprise Asset Management
Application Express 4.1 New Features Hilary Farrell, Principal Member of Technical Staff, Oracle.
1.
1Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 8 Reporting from Contract.
Systems analysis and design, 6th edition Dennis, wixom, and roth
Lecture 8 Index Organized Tables Clusters Index compression
Oracle9i Database Administrator: Implementation and Administration 1 Chapter 9 Index Management.
ISV Innovation Presented by ISV Innovation Presented by Business Intelligence Fundamentals: Data Loading Ola Ekdahl IT Mentors 9/12/08.
RDB/1 An introduction to RDBMS Objectives –To learn about the history and future direction of the SQL standard –To get an overall appreciation of a modern.
Basel · Baden · Bern · Lausanne · Zurich · Düsseldorf · Frankfurt/M. · Freiburg i. Br. · Hamburg · Munich · Stuttgart · Vienna Partitioning Your Oracle.
1 Oracle Database 11g – Flashback Data Archive. 2 Data History and Retention Data retention and change control requirements are growing Regulatory oversight.
Oracle company confidential, Oracle company confidential, 2006 International Withholding & Prepayments Ramakrishnan Balaji Payables Product Strategy.
A first look at table partitioning PUG Challenge Americas Richard Banville & Havard Danielsen OpenEdge Development June 9, 2014.
© 2007 by Prentice Hall (Hoffer, Prescott & McFadden) 1 Introduction to SQL.
© 2009 Pearson Education, Inc. Publishing as Prentice Hall 1 UNIT 6: Chapter 7: Introduction to SQL Modern Database Management 9 th Edition Jeffrey A.
1 of 31 Title Slide Learn How To Partition In Oracle 9i Release 2 Reference Number: #31316 By Eric Yen System Consultant Quest Software.
1Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 8 Contract Management.
Oracle 11g Data Warehousing Vincent Chazhoor Data Warehouse Architect Lafarge North America IOUG collaborate 08 Paper # 204.
3 Copyright © 2005, Oracle. All rights reserved. Partitioning Basics.
Data Warehouse Design Xintao Wu University of North Carolina at Charlotte Nov 10, 2008.
“INTRODUCTION TO DATABASE AND SQL”. Outlines 2  Introduction To Database  Database Concepts  Database Properties  What is Database Management System.
10/10/2012ISC239 Isabelle Bichindaritz1 Physical Database Design.
6.1 © 2010 by Prentice Hall 6 Chapter Foundations of Business Intelligence: Databases and Information Management.
“This presentation is for informational purposes only and may not be incorporated into a contract or agreement.”
1Copyright © 2011, Oracle and/or its affiliates. All rights reserved.
Chapter 9 Logical Database Design : Mapping ER Model To Tables.
Praveen Srivatsa Director| AstrhaSoft Consulting blogs.asthrasoft.com/praveens |
Workforce Scheduling Release 5.0 for Windows Implementation Overview OWS Development Team.
Physical Database Design Purpose- translate the logical description of data into the technical specifications for storing and retrieving data Goal - create.
Partition Architecture Yeon JongHeum
Chapter 4 Logical & Physical Database Design
Managing Schema Objects
Chapter 5 Index and Clustering
Object storage and object interoperability
Last Updated : 27 th April 2004 Center of Excellence Data Warehousing Group Teradata Performance Optimization.
CERN/IT/DB Oracle9i & VLDB Montse Collados Polidura, IT/DB Database Workshop - July 2001.
Oracle SIS and Sakai Integration Linda Feng, Architect Oracle Academic Enterprise Initiative.
Unit 6 Seminar. Indexed Organized Tables Definition: Index Organized Tables are tables that, unlike heap tables, are organized like B*Tree indexes.
CSC314 DAY 8 Introduction to SQL 1. Chapter 6 © 2013 Pearson Education, Inc. Publishing as Prentice Hall SQL OVERVIEW  Structured Query Language  The.
1 Database Fundamentals Introduction to SQL. 2 SQL Overview Structured Query Language The standard for relational database management systems (RDBMS)
Copyright © 2013, Oracle and/or its affiliates. All rights reserved. 1.
Copyright © 2013, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 12 1.
Oracle Enterprise Planning and Budgeting May 21, 2004 Mike Hipps Principal Sales Consultant North American Sales © 2003, 2004 Oracle Corporation. All.
More SQL: Complex Queries, Triggers, Views, and Schema Modification
“Introduction To Database and SQL”
Physical Database Design and Performance
Finding more space for your tight environment
The Ins and Outs of Partitioned Tables
CHAPTER 5: PHYSICAL DATABASE DESIGN AND PERFORMANCE
“Introduction To Database and SQL”
What Is a View? EMPNO ENAME JOB EMP Table EMPVU10 View
Physical Database Design
Processing Tabular Models
INTRODUCTION A Database system is basically a computer based record keeping system. The collection of data, usually referred to as the database, contains.
Presentation transcript:

Oracle Partitioning – Yesterday, Today, and Tomorrow Ananth Raghavan Senior Development Manager, Oracle Partitioning

The following is intended to outline our general product direction. It is intended for information purposes only, and may not be incorporated into any contract. It is not a commitment to deliver any material, code, or functionality, and should not be relied upon in making purchasing decisions. The development, release, and timing of any features or functionality described for Oracle’s products remain at the sole discretion of Oracle.

Agenda History and evolution of Oracle Partitioning Proven functionality in 7 th generation Fundamental concepts for success Resolving some myths Upcoming new functionality Q&A

Agenda History and evolution of Oracle Partitioning Proven functionality in 7 th generation Fundamental concepts for success Resolving some myths Upcoming new functionality Q&A

It is Powerful functionality to logically partition objects into smaller pieces Only driven by business requirements Partitioning for Performance, Manageability, and Availability It is not Just a way to physically divide – or clump - any large data set into smaller buckets Enabling pre-requirement to support a specific hardware/software design Hash mandatory for shared nothing systems What is Oracle Partitioning?

Logical Partitioning Does not underlie any constraints SMP, MPP, Cluster, Grid does not matter Purely based on the business requirement Availability. Manageability, Performance Beneficial for every environment Provides the most comprehensive functionality DB Physical versus Logical Partitioning Shared Everything Architecture - Oracle

Physical Partitioning Fundamental system setup requirement Node owns piece of DB Enables parallelism Number of partitions is equivalent to min. parallelism Always needs HASH distribution Equally sized partitions per node required for proper load balancing DB Physical versus Logical Partitioning Shared Nothing Architecture

Oracle 8.0 RANGE partitioning Fundamental Maintenance operations Static pruning Oracle8 i HASH, composite RANGE-HASH MERGE partitions Dynamic pruning Partition-wise joins Oracle9 i Release 1 LIST partitioning Global index maintenance Oracle9 i Release 2 Fast Split Composite RANGE-LIST DEFAULT partition for LIST Oracle Database10g Release 1 Internal re-architecture (scalability) Global hash-partitioned indexes Local index maintenance Oracle Database 10g Release 2 One million partitions Multi-dimensional pruning Resource optimized drop table * Lots of enhancements not shown here, e.g. IOTs, MVs Oracle Partitioning The way to Oracle Database 10g Release 2 Core functionality: Partitioning techniques

* Lots of enhancements not shown here, e.g. IOTs, MVs Oracle Partitioning The way to Oracle Database 10g Release 2 Partition Maintenance Oracle 8.0 RANGE partitioning Fundamental Maintenance operations Static pruning Oracle8 i HASH, composite RANGE-HASH MERGE partitions Dynamic pruning Partition-wise joins Oracle9 i Release 1 LIST partitioning Global index maintenance Oracle9 i Release 2 Fast Split Composite RANGE-LIST DEFAULT partition for LIST Oracle Database10g Release 1 Internal re-architecture (scalability) Global hash-partitioned indexes Local index maintenance Oracle Database 10g Release 2 One million partitions Multi-dimensional pruning Resource optimized drop table

* Lots of enhancements not shown here, e.g. IOTs, MVs Oracle Partitioning The way to Oracle Database 10g Release 2 Performance Oracle 8.0 RANGE partitioning Fundamental Maintenance operations Static pruning Oracle8 i HASH, composite RANGE-HASH MERGE partitions Dynamic pruning Partition-wise joins Oracle9 i Release 1 LIST partitioning Global index maintenance Oracle9 i Release 2 Fast Split Composite RANGE-LIST DEFAULT partition for LIST Oracle Database10g Release 1 Internal re-architecture (scalability) Global hash-partitioned indexes Local index maintenance Oracle Database 10g Release 2 One million partitions Multi-dimensional pruning Resource optimized drop table

Agenda History and evolution of Oracle Partitioning Proven functionality in 7 th generation Fundamental concepts for success Resolving some myths Upcoming new functionality Q&A

Oracle Partitioning Fundamental Concepts for Success While performance seems to be the most visible one, don't forget about the rest, e.g. Partitioning must address all business-relevant areas of Performance, Manageability, and Availability Partition autonomy is crucial Fundamental requirement for any partition maintenance operations Acknowledge partitions as metadata in the data dictionary

Oracle Partitioning Fundamental Concepts for Success Provide full partition autonomy Use local indexes whenever possible Enable partition all table-level operations for partitions, e.g. TRUNCATE, MOVE, COMPRESS Make partitions visible and usable for database administration Partition naming for ease of use Maintenance operations must be partition-aware Also true for indexes Maintenance operations must not interfere with online usage of a partitioned table

Agenda History and evolution of Oracle Partitioning Proven functionality in 7 th generation Fundamental concepts for success Resolving some myths Upcoming new functionality Q&A

Resolving some Myths “Global Index maintenance is bad” Partition maintenance takes longer when global indexes are updated Global index maintenance is incremental No complete rebuild Fully transparent Table and partition are not locked Continuous and transparent availability

Resolving some Myths “Oracle cannot add or remove data from a partitioned table” Oracle provides the most comprehensive set of data add and removal operations DROP removes a partition, including data and metadata TRUNCATE provides a fast data removal, preserving the metadata EXCHANGE provides the capability to exchange a partition with a standalone table Preserves data for both sides of the exchange Fast data in Fast data out

Resolving some Myths “Local indexes are not important and cannot be used as primary or unique index” Local indexes are crucial for full partition autonomy Logical grouping of partition and index segments enables fast maintenance operations Only local indexes enable full physical data separation for partitioned objects Local indexes can be unique or primary keys Inclusion of partitioning key mandatory for local autonomy Most indexes are non-unique

Resolving some Myths “Oracle's Partition creation syntax is worse than the syntax of other vendors” No “syntactical sugar’ in SQL for initial object creation Provided by Enterprise Manager No metadata extension Subpartition templates provide real metadata Initial creation and future partitions It’s getting even better.. Stay tuned for the upcoming new features section

Resolving some Myths “.. Create partitions every month..”

Resolving some Myths

History and evolution of Oracle Partitioning Proven functionality in 7 th generation Fundamental concepts for success Resolving some myths Upcoming new functionality Q&A Agenda

Future Directions (OW 2004/2005 slide)

Partition techniques enable partitioning for your business The more techniques the better Map your business process the most optimal way Oracle Database 11g enhances the existing partitioning strategies significantly Extended composite partitioning strategies Virtual column based partitioning Interval Partitioning REF Partitioning Extended Partitioning Strategies

Extended Composite Partitioning

Concept of composite partitioning Data is partitioned along two dimensions (A,B) A distinct value pair for the two dimensions uniquely determines the target partitioning Composite partitioning is complementary to multi- column range partitioning Extensions in Oracle Database 11g List-Range Range-Range List-Hash List-List Extended Composite Partitioning Strategies

Table SALES RANGE(order_date)-RANGE(ship_date) Jan Feb 2006Mar 2006Jan Jan 2006 Feb 2006 Jan 2007 Composite Partitioning - Concept

Table SALES RANGE(order_date)-RANGE(ship_date) Jan Feb 2006Mar 2006Jan Jan 2006 Feb 2006 May 2006 Mar 2006 All records with order_date in March 2006

Composite Partitioning - Concept Table SALES RANGE(order_date)-RANGE(ship_date) Jan Feb 2006Mar 2006Jan Jan 2006 Feb 2006 May 2006 All records with ship_date in May 2006 May 2006

Composite Partitioning - Concept Table SALES RANGE(order_date)-RANGE(ship_date) Jan Feb 2006Mar 2006Jan Jan 2006 Feb 2006 May 2006 Mar 2006 All records with order_date in March 2006 AND ship_date in May 2006 May 2006

Virtual Column based Partitioning

Virtual Columns Extended Schema attributes are fully derived and dependent on existing common data Redundant storage or extended view definitions are solving this problem today Requires additional maintenance and creates overhead Business Problem Solution Oracle Database 11g introduces virtual columns Purely virtual, meta-data only Treated as real columns except no DML Virtual columns can have statistics Virtual columns are eligible as partitioning key Enhanced performance and manageability

Virtual Columns - Example Base table with all attributes... CREATE TABLE accounts (acc_no number(10) not null, acc_name varchar2(50) not null, Adams Blake Smith King

Virtual Columns - Example Adams Blake Smith King CREATE TABLE accounts (acc_no number(10) not null, acc_name varchar2(50) not null,... acc_branch number(2) generated always as (to_number(substr(to_char(acc_no),1,2))) 12 Base table with all attributes is extended with the virtual (derived) column

Virtual Columns - Example Adams Blake Smith King CREATE TABLE accounts (acc_no number(10) not null, acc_name varchar2(50) not null,... acc_branch number(2) generated always as (to_number(substr(to_char(acc_no),1,2))) partition by list (acc_branch) Base table with all attributes is extended with the virtual (derived) column... and the virtual column is used as partitioning key Jones Clark Phillips Hurd

Interval Partitioning

Partitioning is key-enabling functionality for managing large volumes of data One logical object for application transparency Multiple physical segments for Administration Improves Manageability, Availability, and Performance Mar Jan Feb CDRs SQL Application Automate the partition management BUT Physical segmentation requires additional data management overhead E.g. new partitions must be created on-time for new data

Interval Partitioning Extension to Range Partitioning Full automation for equi-sized range partitions Partitions are created as metadata information only Start Partition is made persistent Segments are allocated as soon as new data arrives No need to create new partitions Local indexes are created and maintained as well No need for any partition management

Interval Partitioning CREATE TABLE sales (order_date DATE,...) PARTITON BY RANGE (order_date) INTERVAL(NUMTOYMINTERVAL(1,'month') (PARTITION p_first VALUES LESS THAN ('01-JAN-2006'); Table SALES Jan Feb 2006 Mar 2006Jan 2007Oct 2009Nov First segment is created As easy as One, Two, Three..

Interval Partitioning Table SALES Jan Feb 2006 Mar 2006Jan 2007Oct 2009Nov Other partitions only exist in metadata As easy as One, Two, Three.. CREATE TABLE sales (order_date DATE,...) PARTITON BY RANGE (order_date) INTERVAL(NUMTOYMINTERVAL(1,'month') (PARTITION p_first VALUES LESS THAN ('01-JAN-2006');

Interval Partitioning Table SALES Jan Feb 2006 Mar 2006Jan 2007Oct 2009Nov INSERT INTO sales (order_date DATE,...) VALUES ('04-MAR-2006',...); New segment is automatically allocated As easy as One, Two, Three.. CREATE TABLE sales (order_date DATE,...) PARTITON BY RANGE (order_date) INTERVAL(NUMTOYMINTERVAL(1,'month') (PARTITION p_first VALUES LESS THAN ('01-JAN-2006');

Interval Partitioning Table SALES Jan Feb 2006 Mar 2006Jan 2007Oct 2009Nov INSERT INTO sales (order_date DATE,...) VALUES ('17-OCT-2009',...);... whenever data for a new partition arrives As easy as One, Two, Three.. CREATE TABLE sales (order_date DATE,...) PARTITON BY RANGE (order_date) INTERVAL(NUMTOYMINTERVAL(1,'month') (PARTITION p_first VALUES LESS THAN ('01-JAN-2006');

Interval Partitioning Table SALES Jan Feb 2006 Mar 2006Jan 2007Oct 2009Nov Interval partitioned table can have classical range and automated interval section Automated new partition management plus full partition maintenance capabilities: “Best of both worlds”

Interval Partitioning Table SALES Jan Feb 2006 Mar 2006Jan 2007Oct 2009Nov Interval partitioned table can have classical range and automated interval section Automated new partition management plus full partition maintenance capabilities: “Best of both worlds” 1. MERGE and move old partitions for ILM Range partition section

Interval Partitioning Table SALES Jan Feb 2006 Mar 2006Jan 2007Oct 2009Nov Interval partitioned table can have classical range and automated interval section Automated new partition management plus full partition maintenance capabilities: “Best of both worlds” 1. MERGE and move old partitions for ILM Range partition section Interval partition section VALUES ('13-NOV-2009') 1. Insert new data - Automatic segment creation

Interval Partitioning Table SALES Q1 2006Oct 2006 Range partitioned tables can be extended into interval partitioned tables Simple metadata command Investment protection Q

Interval Partitioning Table SALES Q1 2006Oct 2006 Q ALTER TABLE sales (order_date DATE,...) SET INTERVAL(NUMTOYMINTERVAL(1,'month'); Range partitioned tables can be extended into interval partitioned tables Simple metadata command Investment protection... New monthly Interval partitions Old range partition table...

REF Partitioning

Related tables benefit from same partitioning strategy Sample order – lineitem Redundant storage of the same information solves this problem Data overhead Maintenance overhead Business Problem Solution Oracle Database 11g introduces REF Partitioning Child table inherits the partitioning strategy of parent table through PK-FK relationship Intuitive modelling Enhanced Performance and Manageability

Before REF Partitioning Table ORDERS Jan Feb 2006 Table LINEITEMS Jan Feb 2006 RANGE(order_date) Primary key order_id RANGE(order_date) Foreign key order_id Redundant storage of order_date Redundant maintenance

REF Partitioning Table ORDERS Jan Feb 2006 Table LINEITEMS Jan Feb 2006 RANGE(order_date) Primary key order_id RANGE(order_date) Foreign key order_id RANGE(order_date) Foreign key order_id PARTITION BY REFERENCE Partitioning key inherited through PK-FK relationship

Proven functionality in 7 th generation Experience comes with age and customer usage Fundamental concepts for success The most comprehensive and complete offering There will be always myths.. and envious competitors Ground-breaking new functionality available soon 8 th generation will be even better Oracle Partitioning

Proven functionality in 8 th generation Experience comes with age and customer usage Fundamental concepts for success The most comprehensive and complete offering There will be always myths.. and envious competitors Ground-breaking new functionality available soon 9 th generation will be even better There is always room for improvements Any ideas?? Oracle Partitioning

The preceding is intended to outline our general product direction. It is intended for information purposes only, and may not be incorporated into any contract. It is not a commitment to deliver any material, code, or functionality, and should not be relied upon in making purchasing decisions. The development, release, and timing of any features or functionality described for Oracle’s products remain at the sole discretion of Oracle.

A Q &

For More Information or Oracle Partitioning