Robust Optimization of Database Queries

Size: px
Start display at page:

Download "Robust Optimization of Database Queries"

Transcription

1 Robust Optimization of Database Queries Jayant Haritsa Database Systems Lab Indian Institute of Science July 2011 Robust Query Optimization (IASc Mid-year Meeting) 1

2 Database Management Systems (DBMS) Efficient i and convenient mechanisms for storing, maintenance and querying of enterprise data banking, inventory, insurance, travel, Cornerstone of computer industry Uses more than 80 percent of computers worldwide Employs more than 70 percent of IT professionals Largest monetary sector of computer business July 2011 Robust Query Optimization (IASc Mid-year Meeting) 2

3 Current Database Systems Commercial IBM DB2 / Oracle / Microsoft SQL Server / Sybase ASE / CA Ingres Public-Domain PostgreSQL / MySQL July 2011 Robust Query Optimization (IASc Mid-year Meeting) 3

4 Relational Database Systems [RDBMS] Based on first-order logic Edgar Codd of IBM Research, Turing Award (1981) We believe in Codd, not God Data is stored in a set of relations (i.e. tables) with attributes, relationships, constraints STUDENT COURSE Roll No N Name Add Address Course No Titl Title C Credits REGISTER Roll No Course No Grade July 2011 Robust Query Optimization (IASc Mid-year Meeting) 4

5 QUERY INTERFACE Structured Query Language (SQL) Invented by IBM, 1970s Example: List names of students t and their course titles select STUDENT.Name, Name COURSE.Title from STUDENT, COURSE, REGISTER where STUDENT.RollNo = REGISTER.RollNo and REGISTER.CourseNo = COURSE.CourseNo STUDENT Roll No Name Address COURSE Course No Title Credits REGISTER Roll No Course No Grade July 2011 Robust Query Optimization (IASc Mid-year Meeting) 5

6 Query Execution Plans SQL is a declarative language Specifies only what is wanted, but not how the query should be evaluated (i.e. ends, not means) select STUDENT.Name, COURSE.Title from STUDENT, COURSE, REGISTER where STUDENT.RollNo = REGISTER.RollNo and REGISTER.CourseNo = COURSE.CourseNo Unspecified: join order [ ((S R) C) or ((R C) S)? ] join techniques [ Nested-Loops or Sort-Merge or Hash? ] DBMS query optimizer identifies the optimal evaluation strategy: query execution plan July 2011 Robust Query Optimization (IASc Mid-year Meeting) 6

7 Sample Execution Plan RETURN Cost: Total Execution Cost (estimated) HASH JOIN Cost: MERGE JOIN Cost: TABLE SCAN Cost: 6834 INDEX SCAN Cost: 6745 SORT Cost: TABLE SCAN Cost: STUDENT COURSE REGISTER July 2011 Robust Query Optimization (IASc Mid-year Meeting) 7

8 CONCEPT: PLAN DIAGRAMS July 2011 Robust Query Optimization (IASc Mid-year Meeting) 8

9 Relational Selectivities Cost-based Query Optimizer s choice of execution plan = f (query, database, system, ) For a given database and system setup, execution plan chosen for a query = f (selectivities of query s base relations) selectivity is the estimated percentage of rows of a relation used in producing the query result April 2011 Plan Diagrams Tutorial (ICDE 2011) 9

10 SQL Query Template [Q7 of TPC-H HBenchmark] Determines the values of goods shipped between nations in a time period select supp_nation, cust_nation, l_year, sum(volume) as revenue from (select n1.n_name as supp_nation, n2.n_name as cust_nation, extract(year from l_ shipdate) as l_y year, l_extendedprice * (1 - l_discount) as volume from supplier, lineitem, orders, customer, nation n1, nation n2 where s_suppkey Value determines = l_suppkey and o_orderkey = l_orderkey and c_custkey selectivity it= of o_custkey and s_nationkey = n1.n_nationkey selectivity of and ORDERS c_nationkey relation = n2.n_nationkey and ((n1.n_name = 'FRANCE' and n2.n_name = 'GERMANY') or (n1.n_name = 'GERMANY' and n2.n_name = 'FRANCE')) and l_shipdate between date ' ' and date ' ' and o_ totalprice C1 and c_ acctbal C2 ) as shipping group by supp_nation, cust_nation, l_year order by supp_nation, cust_nation, l_year Value determines CUSTOMER relation July 2011 Robust Query Optimization (IASc Mid-year Meeting) 10

11 Relational Selectivity Space ctivity Selec Selectivity July 2011 Robust Query Optimization (IASc Mid-year Meeting) 11

12 Plan and Cost Diagrams A plan diagram is a pictorial enumeration of the plan choices of the query optimizer over the relational selectivity space A cost diagram is a visualization of the (estimated) plan execution costs over the same relational selectivity space July 2011 Robust Query Optimization (IASc Mid-year Meeting) 12

13 PICASSO Picasso is a Java tool developed in our lab that automatically generates plan and cost diagrams ~50000 lines of code ( ) with ~100 classes Operational on DB2/Oracle/SQLServer/Sybase/PostgreSQL Copyrighted by IISc in May 2006 Released as free software in Nov 2006 by Prof. N Balakrishnan, Associate Director of IISc Release of v1.0 in May 2007, v2.0 in Feb 2009, v2.1 in Feb 2011 In use at academic and industrial labs worldwide CMU, Purdue, Duke, TU Munich, NU Singapore, IIT-B, IBM, Microsoft, Oracle, Sybase, HP, Received Best Software award in Very Large Data Base (VLDB) conference, 2010 July 2011 Robust Query Optimization (IASc Mid-year Meeting) 13

14 The Picasso Connection Plan diagrams are often similar to cubist paintings! Woman with a guitar Georges Braque, 1913 [ Pablo Picasso founder of cubist genre ] July 2011 Robust Query Optimization (IASc Mid-year Meeting) 14

15 Complex Plan Diagram [QT8,OptA*] Highly irregular plan boundaries # of plans: 76 The Picasso Connection Intricate Complex Patterns Extremely finegrained coverage (P76 ~ 0.01%) July 2011 Robust Query Optimization (IASc Mid-year Meeting) 15

16 Cost Diagram [QT8, Opt A*] All costs are within 20 percent of the maximum MinCost: 8.26E5 MaxCost: 1.05E6 July 2011 Robust Query Optimization (IASc Mid-year Meeting) 16

17 PHENOMENA: PLAN DIAGRAM REDUCTION July 2011 Robust Query Optimization (IASc Mid-year Meeting) 17

18 Problem Statement Can the plan diagram be recolored with a smaller set of colors (i.e. some plans are swallowed by others), such that Guarantee: No query point in the original diagram has its estimated cost increased, post-swallowing, by more than λ percent (user-defined) d) Analogy: (with due apologies to Sri Lankans in the audience) Sri Lanka agrees to be annexed by India if it is assured that the cost of living of each Lankan citizen is not increased by more than λ percent July 2011 Robust Query Optimization (IASc Mid-year Meeting) 18

19 Reduced Complex Plan Diagram [λ=10%] [QT8, OptA*, Res=100] QTD: QT8_OptA*_100 Reduced to 5 plans from 76! Comparatively smoother contours July 2011 Robust Query Optimization (IASc Mid-year Meeting) 19

20 Anorexic Reduction Extensive empirical evaluation with a spectrum of multi-dimensional query templates indicates that With a cost-increase-threshold of just 20%, virtually all complex plan diagrams [irrespective of query templates, data distribution, query distribution, system configurations, etc.] reduce to anorexic levels (~10 or less plans)! February 2011 Picasso (IIITM Kerala) 20

21 APPLICATION: ROBUST PLANS July 2011 Robust Query Optimization (IASc Mid-year Meeting) 21

22 Selectivity Estimation Errors q e (x e, y e ) : estimated location by optimizer q a (x a, y a ): actual location during execution The difference could be substantial due to Outdated Statistics (expensive to maintain) Coarse Summaries (histograms) Attribute Value Independence (AVI) assumptions Chronic problem in database design July 2011 Robust Query Optimization (IASc Mid-year Meeting) 22

23 Impact of Error Example L I N E I T E M Estimated Query Location (q e ): (1, 40) Cost(P oe ) = 9 x 10 4 (optimal) Actual Query Location (q a ): (80,80) Cost(P oa ) = 50 x 10 4 (optimal) Cost(P oe ) = 110 x 10 4 (highly sub-optimal) Selectivity Space S Space S ORDERS July 2011 Robust Query Optimization (IASc Mid-year Meeting) 23

24 Error Locations wrt Plan Replacement Regions??? Inherently robust 100 Inherently robust q a S Y q a Endo-optimal re Selec ctivity q e `` q a Swallow re Exo-optimalre 0 Selectivity X July 2011 Robust Query Optimization (IASc Mid-year Meeting) 24

25 Positive Impact of Reduction In most cases, replacement plan provides robustness to selectivity errors even in exo-optimal region QT5 q e = (0.36, 0.05) q e (, ) Original Plan (P oe ) Replacement Plan (P re ) P 37 P 1 P 3 P 6 P 4 P 4 Local Optimal Plan (P oa ) July 2011 Robust Query Optimization (IASc Mid-year Meeting) 25

26 Negative Impact of Reduction But, occasionally, the replacement is much worse than the original plan! QT5 q e = (0.03, 0.14) Replacement Plan (P re ) Original Plan (P oe ) P 37 P 1 P 3 P 6 P 4 P 4 Local Optimal Plan (P oa ) July 2011 Robust Query Optimization (IASc Mid-year Meeting) 26

27 Research Challenge How do we ensure that plan replacements can only help, but never materially hurt the expected performance? July 2011 Robust Query Optimization (IASc Mid-year Meeting) 27

28 Our Contribution Mathematical analysis to show that only the perimeter of the selectivity space suffices to determine global safety Border Safety Interior Safety! April 2011 Plan Diagrams Tutorial (ICDE 2011) 28

29 Take Away We can efficiently i produce plan diagrams that simultaneously possess the desirable properties of being online, anorexic, safe and robust. This result could play a meaningful role in designing g the next generation of database query optimizers. July 2011 Robust Query Optimization (IASc Mid-year Meeting) 29

30 More Details i / /PICASSO Publications, Software, Sample Diagrams July 2011 Robust Query Optimization (IASc Mid-year Meeting) 30

31 Dedication Name: Dr B K Narayana Rao (Founding Fellow) Born: 1881 Elected: 1934 Section: Medicine Council Service: ; Vice President Name: Prof T S Subbaraya Born: 1905 Elected: 1935 Section: Physics Name: Dr B N Balakrishna Rao Born: 1910 Elected: 1945 Section: Medicine July 2011 Robust Query Optimization (IASc Mid-year Meeting) 31

32 QUESTIONS? July 2011 Robust Query Optimization (IASc Mid-year Meeting) 32

33 END PRESENTATION July 2011 Robust Query Optimization (IASc Mid-year Meeting) 33

Anorexic Plan Diagrams

Anorexic Plan Diagrams Anorexic Plan Diagrams E0 261 Jayant Haritsa Computer Science and Automation Indian Institute of Science JAN 2014 Plan Diagram Reduction 1 Query Plan Selection Core technique Query (Q) Query Optimizer

More information

Towards Comprehensive Testing Tools

Towards Comprehensive Testing Tools Towards Comprehensive Testing Tools Redefining testing mechanisms! Kuntal Ghosh (Software Engineer) PGCon 2017 26.05.2017 1 Contents Motivation Picasso Visualizer Picasso Art Gallery for PostgreSQL 10

More information

Jayant Haritsa. Database Systems Lab Indian Institute of Science Bangalore, India

Jayant Haritsa. Database Systems Lab Indian Institute of Science Bangalore, India Jayant Haritsa Database Systems Lab Indian Institute of Science Bangalore, India Query Execution Plans SQL, the standard database query interface, is a declarative language Specifies only what is wanted,

More information

Query Optimizer Plan Diagrams: Production, Reduction and Applications

Query Optimizer Plan Diagrams: Production, Reduction and Applications Query Optimizer Plan Diagrams: Production, Reduction and Applications Jayant Haritsa Database Systems Lab Indian Institute of Science Bangalore, INDIA April 2011 Plan Diagrams Tutorial (ICDE 2011) 1 Cost-based

More information

Histogram Support in MySQL 8.0

Histogram Support in MySQL 8.0 Histogram Support in MySQL 8.0 Øystein Grøvlen Senior Principal Software Engineer MySQL Optimizer Team, Oracle February 2018 Program Agenda 1 2 3 4 5 Motivating example Quick start guide How are histograms

More information

DATABASE MANAGEMENT SYSTEMS

DATABASE MANAGEMENT SYSTEMS DATABASE MANAGEMENT SYSTEMS E0 261 Jayant Haritsa Computer Science and Automation Indian Institute of Science JAN 2017 Slide 1 E0 261 JAN 2017 Slide 2 PRE-REQUISITES Undergrad DBMS course with Basic Concepts,

More information

Oracle. Professional. WITH Function-Based Indexes (FBIs), I was able to alter an execution. Avoid Costly Joins with FBIs Pedro Bizarro.

Oracle. Professional. WITH Function-Based Indexes (FBIs), I was able to alter an execution. Avoid Costly Joins with FBIs Pedro Bizarro. Oracle Solutions for High-End Oracle DBAs and Developers Professional Avoid Costly Joins with FBIs Pedro Bizarro In this article, Pedro Bizarro describes how to use Function-Based Indexes to avoid costly

More information

Technical Report - Distributed Database Victor FERNANDES - Université de Strasbourg /2000 TECHNICAL REPORT

Technical Report - Distributed Database Victor FERNANDES - Université de Strasbourg /2000 TECHNICAL REPORT TECHNICAL REPORT Distributed Databases And Implementation of the TPC-H Benchmark Victor FERNANDES DESS Informatique Promotion : 1999 / 2000 Page 1 / 29 TABLE OF CONTENTS ABSTRACT... 3 INTRODUCTION... 3

More information

Picasso Database Query Optimizer Visualizer

Picasso Database Query Optimizer Visualizer Indian Institute of Science 1 of 130 Picasso Database Query Optimizer Visualizer Version 2.1 Database Systems Lab Supercomputer Education & Research Centre and Department of Computer Science & Automation

More information

Robust Query Processing

Robust Query Processing Robust Query Processing A PROJECT REPORT SUBMITTED IN PARTIAL FULFIMENT OF THE REQUIREMENTS FOR THE DEGREE OF Master of Engineering IN Faculty of Engineering BY Kuntal Ghosh Computer Science and Automation

More information

PLAN DIAGRAMS: Visualizing Database Query Optimizers. Jayant R. Haritsa 1. STUDENT RollNo StudentName Address Program

PLAN DIAGRAMS: Visualizing Database Query Optimizers. Jayant R. Haritsa 1. STUDENT RollNo StudentName Address Program PLAN DIAGRAMS: Visualizing Database Query Optimizers Jayant R. Haritsa 1 Abstract The automated optimization of declarative SQL queries is a classical problem that has been diligently addressed by the

More information

On-Disk Bitmap Index Performance in Bizgres 0.9

On-Disk Bitmap Index Performance in Bizgres 0.9 On-Disk Bitmap Index Performance in Bizgres 0.9 A Greenplum Whitepaper April 2, 2006 Author: Ayush Parashar Performance Engineering Lab Table of Contents 1.0 Summary...1 2.0 Introduction...1 3.0 Performance

More information

High Volume In-Memory Data Unification

High Volume In-Memory Data Unification 25 March 2017 High Volume In-Memory Data Unification for UniConnect Platform powered by Intel Xeon Processor E7 Family Contents Executive Summary... 1 Background... 1 Test Environment...2 Dataset Sizes...

More information

DATABASE MANAGEMENT SYSTEMS

DATABASE MANAGEMENT SYSTEMS DATABASE MANAGEMENT SYSTEMS E0 261 Prasad Deshpande, Jayant Haritsa Computer Science and Automation Indian Institute of Science AUG 2010 Slide 1 db@iisc AUG 2010 Slide 2 COURSES E0 261 (AUG) Database Management

More information

Avoiding Sorting and Grouping In Processing Queries

Avoiding Sorting and Grouping In Processing Queries Avoiding Sorting and Grouping In Processing Queries Outline Motivation Simple Example Order Properties Grouping followed by ordering Order Property Optimization Performance Results Conclusion Motivation

More information

Robust Plans through Plan Diagram Reduction

Robust Plans through Plan Diagram Reduction Robust Plans through Plan Diagram Reduction Harish D. Pooja N. Darera Jayant R. Haritsa Technical Report TR-2007-02 Database Systems Lab Supercomputer Education and Research Centre Indian Institute of

More information

Orri Erling (Program Manager, OpenLink Virtuoso), Ivan Mikhailov (Lead Developer, OpenLink Virtuoso).

Orri Erling (Program Manager, OpenLink Virtuoso), Ivan Mikhailov (Lead Developer, OpenLink Virtuoso). Orri Erling (Program Manager, OpenLink Virtuoso), Ivan Mikhailov (Lead Developer, OpenLink Virtuoso). Business Intelligence Extensions for SPARQL Orri Erling and Ivan Mikhailov OpenLink Software, 10 Burlington

More information

Picasso: Analyzing and Characterizing Relational Query Optimizers

Picasso: Analyzing and Characterizing Relational Query Optimizers Picasso: Analyzing and Characterizing Relational Query Optimizers A Project Report Submitted in Partial Fulfilment of the Requirements for the Degree of Master of Engineering in Internet Science and Engineering

More information

Analyzing the Behavior of a Distributed Database. Query Optimizer. Deepali Nemade

Analyzing the Behavior of a Distributed Database. Query Optimizer. Deepali Nemade Analyzing the Behavior of a Distributed Database Query Optimizer A Project Report Submitted in partial fulfilment of the requirements for the Degree of Master of Engineering in Computer Science and Engineering

More information

VISUAL ANALYSIS OF COST BASED DATABASE OPTIMIZERS USING PICASSO TOOL

VISUAL ANALYSIS OF COST BASED DATABASE OPTIMIZERS USING PICASSO TOOL VISUAL ANALYSIS OF COST BASED DATABASE OPTIMIZERS USING PICASSO TOOL Neeraj Sharma 1, Kavindra Raghuwanshi 2, Syed Imran Ali 3, Banshilal Patidar 4 1 Department of CSE, Trinity Institute of Technology

More information

Optimizer Standof. MySQL 5.6 vs MariaDB 5.5. Peter Zaitsev, Ovais Tariq Percona Inc April 18, 2012

Optimizer Standof. MySQL 5.6 vs MariaDB 5.5. Peter Zaitsev, Ovais Tariq Percona Inc April 18, 2012 Optimizer Standof MySQL 5.6 vs MariaDB 5.5 Peter Zaitsev, Ovais Tariq Percona Inc April 18, 2012 Thank you Ovais Tariq Ovais Did a lot of heavy lifing for this presentation He could not come to talk together

More information

TPC-H Benchmark Set. TPC-H Benchmark. DDL for TPC-H datasets

TPC-H Benchmark Set. TPC-H Benchmark. DDL for TPC-H datasets TPC-H Benchmark Set TPC-H Benchmark TPC-H is an ad-hoc and decision support benchmark. Some of queries are available in the current Tajo. You can download the TPC-H data generator here. DDL for TPC-H datasets

More information

Self-Tuning Database Systems: The AutoAdmin Experience

Self-Tuning Database Systems: The AutoAdmin Experience Self-Tuning Database Systems: The AutoAdmin Experience Surajit Chaudhuri Data Management and Exploration Group Microsoft Research http://research.microsoft.com/users/surajitc surajitc@microsoft.com 5/10/2002

More information

Architecture and Implementation of Database Systems (Winter 2015/16)

Architecture and Implementation of Database Systems (Winter 2015/16) Jens Teubner Architecture & Implementation of DBMS Winter 2015/16 1 Architecture and Implementation of Database Systems (Winter 2015/16) Jens Teubner, DBIS Group jens.teubner@cs.tu-dortmund.de Winter 2015/16

More information

Analyzing Plan Diagrams of Database Query Optimizers

Analyzing Plan Diagrams of Database Query Optimizers Analyzing Plan Diagrams of Database Query Optimizers Naveen Reddy Jayant R. Haritsa Database Systems Lab, SERC/CSA Indian Institute of Science, Bangalore 560012, INDIA Abstract A plan diagram is a pictorial

More information

Efficiently Approximating Query Optimizer Diagrams

Efficiently Approximating Query Optimizer Diagrams Efficiently Approximating Query Optimizer Diagrams A Thesis Submitted for the Degree of Master of Science (Engineering) in the Faculty of Engineering By Atreyee Dey Supercomputer Education and Research

More information

Chapter 1 Introduction

Chapter 1 Introduction Chapter 1 Introduction Contents The History of Database System Overview of a Database Management System (DBMS) Three aspects of database-system studies the state of the art Introduction to Database Systems

More information

Beyond EXPLAIN. Query Optimization From Theory To Code. Yuto Hayamizu Ryoji Kawamichi. 2016/5/20 PGCon Ottawa

Beyond EXPLAIN. Query Optimization From Theory To Code. Yuto Hayamizu Ryoji Kawamichi. 2016/5/20 PGCon Ottawa Beyond EXPLAIN Query Optimization From Theory To Code Yuto Hayamizu Ryoji Kawamichi 2016/5/20 PGCon 2016 @ Ottawa Historically Before Relational Querying was physical Need to understand physical organization

More information

Efficiently Approximating Query Optimizer Plan Diagrams

Efficiently Approximating Query Optimizer Plan Diagrams Efficiently Approximating Query Optimizer Plan Diagrams Atreyee Dey Sourjya Bhaumik Harish D. Jayant R. Haritsa Database Systems Lab, SERC/CSA Indian Institute of Science, Bangalore 560012, INDIA ABSTRACT

More information

Advanced Query Optimization

Advanced Query Optimization Advanced Query Optimization Andreas Meister Otto-von-Guericke University Magdeburg Summer Term 2018 Why do we need query optimization? Andreas Meister Advanced Query Optimization Last Change: April 23,

More information

Parallelism Strategies In The DB2 Optimizer

Parallelism Strategies In The DB2 Optimizer Session: A05 Parallelism Strategies In The DB2 Optimizer Calisto Zuzarte IBM Toronto Lab May 20, 2008 09:15 a.m. 10:15 a.m. Platform: DB2 on Linux, Unix and Windows The Database Partitioned Feature (DPF)

More information

Introduction to Database Systems

Introduction to Database Systems Introduction to Database Systems UVic C SC 370 Daniel M German Introduction to Database Systems (1.2.0) CSC 370 4/5/2005 14:51 p.1/27 Overview What is a DBMS? what is a relational DBMS? Why do we need

More information

Lazy Maintenance of Materialized Views

Lazy Maintenance of Materialized Views Lazy Maintenance of Materialized Views Jingren Zhou, Microsoft Research, USA Paul Larson, Microsoft Research, USA Hicham G. Elmongui, Purdue University, USA Introduction 2 Materialized views Speed up query

More information

QUERY OPTIMIZATION E Jayant Haritsa Computer Science and Automation Indian Institute of Science. JAN 2014 Slide 1 QUERY OPTIMIZATION

QUERY OPTIMIZATION E Jayant Haritsa Computer Science and Automation Indian Institute of Science. JAN 2014 Slide 1 QUERY OPTIMIZATION E0 261 Jayant Haritsa Computer Science and Automation Indian Institute of Science JAN 2014 Slide 1 Database Engines Main Components Query Processing Transaction Processing Access Methods JAN 2014 Slide

More information

MOIRA A Goal-Oriented Incremental Machine Learning Approach to Dynamic Resource Cost Estimation in Distributed Stream Processing Systems

MOIRA A Goal-Oriented Incremental Machine Learning Approach to Dynamic Resource Cost Estimation in Distributed Stream Processing Systems MOIRA A Goal-Oriented Incremental Machine Learning Approach to Dynamic Resource Cost Estimation in Distributed Stream Processing Systems Daniele Foroni, C. Axenie, S. Bortoli, M. Al Hajj Hassan, R. Acker,

More information

Two-Phase Optimization for Selecting Materialized Views in a Data Warehouse

Two-Phase Optimization for Selecting Materialized Views in a Data Warehouse Two-Phase Optimization for Selecting Materialized Views in a Data Warehouse Jiratta Phuboon-ob, and Raweewan Auepanwiriyakul Abstract A data warehouse (DW) is a system which has value and role for decision-making

More information

An Overview of various methodologies used in Data set Preparation for Data mining Analysis

An Overview of various methodologies used in Data set Preparation for Data mining Analysis An Overview of various methodologies used in Data set Preparation for Data mining Analysis Arun P Kuttappan 1, P Saranya 2 1 M. E Student, Dept. of Computer Science and Engineering, Gnanamani College of

More information

B.H.GARDI COLLEGE OF MASTER OF COMPUTER APPLICATION. Ch. 1 :- Introduction Database Management System - 1

B.H.GARDI COLLEGE OF MASTER OF COMPUTER APPLICATION. Ch. 1 :- Introduction Database Management System - 1 Basic Concepts :- 1. What is Data? Data is a collection of facts from which conclusion may be drawn. In computer science, data is anything in a form suitable for use with a computer. Data is often distinguished

More information

6.830 Problem Set 2 (2017)

6.830 Problem Set 2 (2017) 6.830 Problem Set 2 1 Assigned: Monday, Sep 25, 2017 6.830 Problem Set 2 (2017) Due: Monday, Oct 16, 2017, 11:59 PM Submit to Gradescope: https://gradescope.com/courses/10498 The purpose of this problem

More information

Midterm Review. March 27, 2017

Midterm Review. March 27, 2017 Midterm Review March 27, 2017 1 Overview Relational Algebra & Query Evaluation Relational Algebra Rewrites Index Design / Selection Physical Layouts 2 Relational Algebra & Query Evaluation 3 Relational

More information

CSC 4710 / CSC 6710 Database Systems. Rao Casturi

CSC 4710 / CSC 6710 Database Systems. Rao Casturi CSC 4710 / CSC 6710 Database Systems Rao Casturi Introduction About me Education B.E (Electronics & Communications) M.S (Computer Science) Working towards Ph.D. Professional work experience 25+ Years in

More information

DATABASE MANAGEMENT SYSTEMS. UNIT I Introduction to Database Systems

DATABASE MANAGEMENT SYSTEMS. UNIT I Introduction to Database Systems DATABASE MANAGEMENT SYSTEMS UNIT I Introduction to Database Systems Terminology Data = known facts that can be recorded Database (DB) = logically coherent collection of related data with some inherent

More information

A Comparison of Three Methods for Join View Maintenance in Parallel RDBMS

A Comparison of Three Methods for Join View Maintenance in Parallel RDBMS A Comparison of Three Methods for Join View Maintenance in Parallel RDBMS Gang Luo Jeffrey F. Naughton Curt J. Ellmann Michael W. Watzke Department of Computer Sciences NCR Advance Development Lab University

More information

BIS Database Management Systems.

BIS Database Management Systems. BIS 512 - Database Management Systems http://www.mis.boun.edu.tr/durahim/ Ahmet Onur Durahim Learning Objectives Database systems concepts Designing and implementing a database application Life of a Query

More information

MIS Database Systems.

MIS Database Systems. MIS 335 - Database Systems http://www.mis.boun.edu.tr/durahim/ Ahmet Onur Durahim Learning Objectives Database systems concepts Designing and implementing a database application Life of a Query in a Database

More information

Reduction of Query Optimizer Plan Diagrams

Reduction of Query Optimizer Plan Diagrams Reduction of Query Optimizer Plan Diagrams Harish D. Pooja N. Darera Jayant R. Haritsa Technical Report TR-2007-01 Database Systems Lab Supercomputer Education and Research Centre Indian Institute of Science

More information

Informatics 1: Data & Analysis

Informatics 1: Data & Analysis Informatics 1: Data & Analysis Lecture 7: SQL Ian Stark School of Informatics The University of Edinburgh Tuesday 7 February 2017 Semester 2 Week 4 https://blog.inf.ed.ac.uk/da17 Homework from Friday 1.

More information

Comparison of Database Cloud Services

Comparison of Database Cloud Services Comparison of Database Cloud Services Benchmark Testing Overview ORACLE WHITE PAPER SEPTEMBER 2016 Table of Contents Table of Contents 1 Disclaimer 2 Preface 3 Introduction 4 Cloud OLTP Workload 5 Cloud

More information

Course Introduction & History of Database Systems

Course Introduction & History of Database Systems Course Introduction & History of Database Systems CMPT 843, SPRING 2018 JIANNAN WANG https://sfu-db.github.io/dbsystems/ CMPT 843-2018 SPRING - SFU 1 Introduce Yourself What s your name? Where are you

More information

When and How to Take Advantage of New Optimizer Features in MySQL 5.6. Øystein Grøvlen Senior Principal Software Engineer, MySQL Oracle

When and How to Take Advantage of New Optimizer Features in MySQL 5.6. Øystein Grøvlen Senior Principal Software Engineer, MySQL Oracle When and How to Take Advantage of New Optimizer Features in MySQL 5.6 Øystein Grøvlen Senior Principal Software Engineer, MySQL Oracle Program Agenda Improvements for disk-bound queries Subquery improvements

More information

Analyzing Plan Diagrams of Database Query Optimizers

Analyzing Plan Diagrams of Database Query Optimizers Analyzing Plan Diagrams of Database Query Optimizers Thomas Mayer KIT, Institut für Programmstrukturen und Datenorganisation (IPD), D-76131 Karlsruhe, Germany Abstract. This report concentrates on the

More information

The functions performed by a typical DBMS are the following:

The functions performed by a typical DBMS are the following: MODULE NAME: Database Management TOPIC: Introduction to Basic Database Concepts LECTURE 2 Functions of a DBMS The functions performed by a typical DBMS are the following: Data Definition The DBMS provides

More information

Chapter 1: Introduction

Chapter 1: Introduction Chapter 1: Introduction Database System Concepts, 6 th Ed. See www.db-book.com for conditions on re-use Outline The Need for Databases Data Models Relational Databases Database Design Storage Manager Query

More information

Advanced Migration of Schema and Data across Multiple Databases

Advanced Migration of Schema and Data across Multiple Databases Advanced Migration of Schema and Data across Multiple Databases D.M.W.E. Dissanayake 139163B Faculty of Information Technology University of Moratuwa May 2017 Advanced Migration of Schema and Data across

More information

Efficient Generation of Query Optimizer Diagrams

Efficient Generation of Query Optimizer Diagrams Efficient Generation of Query Optimizer Diagrams A Project Report Submitted in Partial Fulfilment of the Requirements for the Degree of Master of Engineering in Computer Science and Engineering By Sourjya

More information

Getting Started with SAP Sybase IQ Column Store Analytics Server

Getting Started with SAP Sybase IQ Column Store Analytics Server Author: Courtney Claussen SAP Sybase IQ Technical Evangelist Contributor: Bruce McManus Director of Customer Support at Sybase Getting Started with SAP Sybase IQ Column Store Analytics Server Lesson 4:

More information

Efficient in-memory query execution using JIT compiling. Han-Gyu Park

Efficient in-memory query execution using JIT compiling. Han-Gyu Park Efficient in-memory query execution using JIT compiling Han-Gyu Park 2012-11-16 CONTENTS Introduction How DCX works Experiment(purpose(at the beginning of this slide), environment, result, analysis & conclusion)

More information

A practical introduction to database design

A practical introduction to database design A practical introduction to database design Dr. Chris Tomlinson Bioinformatics Data Science Group, Room 126, Sir Alexander Fleming Building chris.tomlinson@imperial.ac.uk Computer Skills Classes 17/01/19

More information

Materialized Views. March 26, 2018

Materialized Views. March 26, 2018 Materialized Views March 26, 2018 1 CREATE VIEW salessincelastmonth AS SELECT l.* FROM lineitem l, orders o WHERE l.orderkey = o.orderkey AND o.orderdate > DATE( 2015-03-31 ) SELECT partkey FROM salessincelastmonth

More information

Recommending Materialized Views and Indexes with the IBM DB2 Design Advisor

Recommending Materialized Views and Indexes with the IBM DB2 Design Advisor Recommending Materialized Views and Indexes with the IBM DB2 Design Advisor Daniel C. Zilio et al Proceedings of the International Conference on Automatic Computing (ICAC 04) Rolando Blanco CS848 - Spring

More information

Big Data Specialized Studies

Big Data Specialized Studies Information Technologies Programs Big Data Specialized Studies Accelerate Your Career extension.uci.edu/bigdata Offered in partnership with University of California, Irvine Extension s professional certificate

More information

Data! CS 133: Databases. Goals for Today. So, what is a database? What is a database anyway? From the textbook:

Data! CS 133: Databases. Goals for Today. So, what is a database? What is a database anyway? From the textbook: CS 133: Databases Fall 2018 Lec 01 09/04 Introduction & Relational Model Data! Need systems to Data is everywhere Banking, airline reservations manage the data Social media, clicking anything on the internet

More information

Schema Tuning. Tuning Schemas : Overview

Schema Tuning. Tuning Schemas : Overview Administração e Optimização de Bases de Dados 2012/2013 Schema Tuning Bruno Martins DEI@Técnico e DMIR@INESC-ID Tuning Schemas : Overview Trade-offs among normalization / denormalization Overview When

More information

Columnstore and B+ tree. Are Hybrid Physical. Designs Important?

Columnstore and B+ tree. Are Hybrid Physical. Designs Important? Columnstore and B+ tree Are Hybrid Physical Designs Important? 1 B+ tree 2 C O L B+ tree 3 B+ tree & Columnstore on same table = Hybrid design 4? C O L C O L B+ tree B+ tree ? C O L C O L B+ tree B+ tree

More information

Why are you here? Introduction. Course roadmap. Course goals. What do you want from a DBMS? What is a database system? Aren t databases just

Why are you here? Introduction. Course roadmap. Course goals. What do you want from a DBMS? What is a database system? Aren t databases just Why are you here? 2 Introduction CPS 216 Advanced Database Systems Aren t databases just Trivial exercises in first-order logic (says AI)? Bunch of out-of-fashion I/O-efficient indexes and algorithms (says

More information

TIM 50 - Business Information Systems

TIM 50 - Business Information Systems TIM 50 - Business Information Systems Lecture 15 UC Santa Cruz May 20, 2014 Announcements DB 2 Due Tuesday Next Week The Database Approach to Data Management Database: Collection of related files containing

More information

presented by: Tim Haithcoat University of Missouri Columbia

presented by: Tim Haithcoat University of Missouri Columbia 12 presented by: Tim Haithcoat University of Missouri Columbia Introduction Very early attempts to build GIS began from scratch, using limited tools like operating systems & compilers More recently, GIS

More information

Comparison of Database Cloud Services

Comparison of Database Cloud Services Comparison of Database Cloud Services Testing Overview ORACLE WHITE PAPER SEPTEMBER 2016 Table of Contents Table of Contents 1 Disclaimer 2 Preface 3 Introduction 4 Cloud OLTP Workload 5 Cloud Analytic

More information

A Compression Framework for Query Results

A Compression Framework for Query Results A Compression Framework for Query Results Zhiyuan Chen and Praveen Seshadri Cornell University zhychen, praveen@cs.cornell.edu, contact: (607)255-1045, fax:(607)255-4428 Decision-support applications in

More information

Tuning Relational Systems I

Tuning Relational Systems I Tuning Relational Systems I Schema design Trade-offs among normalization, denormalization, clustering, aggregate materialization, vertical partitioning, etc Query rewriting Using indexes appropriately,

More information

Chapter 10. Query Optimization. Exploring the Search Space of Alternative Query Plans. Architecture and Implementation of Database Systems

Chapter 10. Query Optimization. Exploring the Search Space of Alternative Query Plans. Architecture and Implementation of Database Systems Chapter 10 Exploring the Search Space of Alternative Query Plans Architecture and Implementation of Database Systems 1 Finding the Best Query Plan Throttle or break? π SELECT FROM WHERE? R NL hash σ T

More information

CSC317/MCS9317. Database Performance Tuning. Class test

CSC317/MCS9317. Database Performance Tuning. Class test CSC317/MCS9317 Database Performance Tuning Class test 7 October 2015 Please read all instructions (including these) carefully. The test time is approximately 120 minutes. The test is close book and close

More information

Exploring the Semantics of Plan Diagrams

Exploring the Semantics of Plan Diagrams Exploring the Semantics of Plan Diagrams A Thesis Submitted for the Degree of Master of Science (Engineering) in the Faculty of Engineering By Bruhathi HS Supercomputer Education and Research Centre INDIAN

More information

Using Relational Databases for Digital Research

Using Relational Databases for Digital Research Using Relational Databases for Digital Research Definition (using a) relational database is a way of recording information in a structure that maximizes efficiency by separating information into different

More information

Database Optimization

Database Optimization Database Optimization June 9 2009 A brief overview of database optimization techniques for the database developer. Database optimization techniques include RDBMS query execution strategies, cost estimation,

More information

Toward a Progress Indicator for Database Queries

Toward a Progress Indicator for Database Queries Toward a Progress Indicator for Database Queries Gang Luo Jeffrey F. Naughton Curt J. Ellmann Michael W. Watzke University of Wisconsin-Madison NCR Advance Development Lab {gangluo, naughton}@cs.wisc.edu

More information

Materialized Views. March 28, 2018

Materialized Views. March 28, 2018 Materialized Views March 28, 2018 1 CREATE VIEW salessincelastmonth AS SELECT l.* FROM lineitem l, orders o WHERE l.orderkey = o.orderkey AND o.orderdate > DATE( 2015-03-31 ) 2 CREATE VIEW salessincelastmonth

More information

Introduction. Who wants to study databases?

Introduction. Who wants to study databases? Introduction Example databases Overview of concepts Why use database systems Who wants to study databases? What is the use of all the courses I have taken so far? This course shows very concrete how CS

More information

Chapter. Relational Database Concepts COPYRIGHTED MATERIAL

Chapter. Relational Database Concepts COPYRIGHTED MATERIAL Chapter Relational Database Concepts 1 COPYRIGHTED MATERIAL Every organization has data that needs to be collected, managed, and analyzed. A relational database fulfills these needs. Along with the powerful

More information

(ADVANCED) DATABASE SYSTEMS (DATABASE MANAGEMENTS) PROF. DR. HASAN HÜSEYİN BALIK (6 TH WEEK)

(ADVANCED) DATABASE SYSTEMS (DATABASE MANAGEMENTS) PROF. DR. HASAN HÜSEYİN BALIK (6 TH WEEK) (ADVANCED) DATABASE SYSTEMS (DATABASE MANAGEMENTS) PROF. DR. HASAN HÜSEYİN BALIK (6 TH WEEK) 4. OUTLINE 4. Implementation 4.1 Introduction to SQL 4.2 Advanced SQL 4.3 Database Application Development 4.4

More information

DBMS. Relational Model. Module Title?

DBMS. Relational Model. Module Title? Relational Model Why Study the Relational Model? Most widely used model currently. DB2,, MySQL, Oracle, PostgreSQL, SQLServer, Note: some Legacy systems use older models e.g., IBM s IMS Object-oriented

More information

Evolution of Database Systems

Evolution of Database Systems Evolution of Database Systems Krzysztof Dembczyński Intelligent Decision Support Systems Laboratory (IDSS) Poznań University of Technology, Poland Intelligent Decision Support Systems Master studies, second

More information

Introduction to Spatial Database Systems

Introduction to Spatial Database Systems Introduction to Spatial Database Systems by Cyrus Shahabi from Ralf Hart Hartmut Guting s VLDB Journal v3, n4, October 1994 Data Structures & Algorithms 1. Implementation of spatial algebra in an integrated

More information

The University of Jordan

The University of Jordan The University of Jordan Faculty: Business Department: Management Information Systems Semester: 1 st and 2 nd Academic Year: Each academic year Database Management Systems (2) [1605440] -----------------------------------------------------------------------------------------------------------

More information

Announcements. References. Selinger Optimizer History. More about the Selinger Algorithm. Selinger Algorithm. CSE 444: Database Internals

Announcements. References. Selinger Optimizer History. More about the Selinger Algorithm. Selinger Algorithm. CSE 444: Database Internals Announcements CSE 444: Database Internals Lab 2 deadline EXTENDED by 24 hours Lab 2 quiz moved to Monday Lecture 12 Query Optimization (part 3) 1 2 Selinger Optimizer History References 1960 s: first database

More information

SEF DATABASE FOUNDATION ON ORACLE COURSE CURRICULUM

SEF DATABASE FOUNDATION ON ORACLE COURSE CURRICULUM On a Mission to Transform Talent SEF DATABASE FOUNDATION ON ORACLE COURSE CURRICULUM Table of Contents Module 1: Introduction to Linux & RDBMS (Duration: 1 Week)...2 Module 2: Oracle SQL (Duration: 3 Weeks)...3

More information

Outline. Database Management Systems (DBMS) Database Management and Organization. IT420: Database Management and Organization

Outline. Database Management Systems (DBMS) Database Management and Organization. IT420: Database Management and Organization Outline IT420: Database Management and Organization Dr. Crăiniceanu Capt. Balazs www.cs.usna.edu/~adina/teaching/it420/spring2007 Class Survey Why Databases (DB)? A Problem DB Benefits In This Class? Admin

More information

Database Fundamentals Chapter 1

Database Fundamentals Chapter 1 Database Fundamentals Chapter 1 Class 01: Database Fundamentals 1 What is a Database? The ISO/ANSI SQL Standard does not contain a definition of the term database. In fact, the term is never mentioned

More information

7. Query Processing and Optimization

7. Query Processing and Optimization 7. Query Processing and Optimization Processing a Query 103 Indexing for Performance Simple (individual) index B + -tree index Matching index scan vs nonmatching index scan Unique index one entry and one

More information

ABSTRACT. GUPTA, SHALU View Selection for Query-Evaluation Efficiency using Materialized

ABSTRACT. GUPTA, SHALU View Selection for Query-Evaluation Efficiency using Materialized ABSTRACT GUPTA, SHALU View Selection for Query-Evaluation Efficiency using Materialized Views (Under the direction of Dr. Rada Chirkova) The purpose of this research is to show the use of derived data

More information

CISC 3140 (CIS 20.2) Design & Implementation of Software Application II

CISC 3140 (CIS 20.2) Design & Implementation of Software Application II CISC 3140 (CIS 20.2) Design & Implementation of Software Application II Instructor : M. Meyer Email Address: meyer@sci.brooklyn.cuny.edu Course Page: http://www.sci.brooklyn.cuny.edu/~meyer/ CISC3140-Meyer-lec4

More information

Interview Questions on DBMS and SQL [Compiled by M V Kamal, Associate Professor, CSE Dept]

Interview Questions on DBMS and SQL [Compiled by M V Kamal, Associate Professor, CSE Dept] Interview Questions on DBMS and SQL [Compiled by M V Kamal, Associate Professor, CSE Dept] 1. What is DBMS? A Database Management System (DBMS) is a program that controls creation, maintenance and use

More information

Introduction. Example Databases

Introduction. Example Databases Introduction Example databases Overview of concepts Why use database systems Example Databases University Data: departments, students, exams, rooms,... Usage: creating exam plans, enter exam results, create

More information

Database Systems: Concepts, design, and implementation ISE 382 (3 Units)

Database Systems: Concepts, design, and implementation ISE 382 (3 Units) Database Systems: Concepts, design, and implementation ISE 382 (3 Units) Spring 2013 Description Obectives Instructor Contact Information Office Hours Concepts in modeling data for industry applications.

More information

Informatics 1: Data & Analysis

Informatics 1: Data & Analysis Informatics 1: Data & Analysis Lecture 7: SQL Ian Stark School of Informatics The University of Edinburgh Tuesday 3 February 2015 Semester 2 Week 4 http://www.inf.ed.ac.uk/teaching/courses/inf1/da Careers

More information

CS143: Relational Model

CS143: Relational Model CS143: Relational Model Book Chapters (4th) Chapters 1.3-5, 3.1, 4.11 (5th) Chapters 1.3-7, 2.1, 3.1-2, 4.1 (6th) Chapters 1.3-6, 2.105, 3.1-2, 4.5 Things to Learn Data model Relational model Database

More information

Database Technology Introduction. Heiko Paulheim

Database Technology Introduction. Heiko Paulheim Database Technology Introduction Outline The Need for Databases Data Models Relational Databases Database Design Storage Manager Query Processing Transaction Manager Introduction to the Relational Model

More information

Introduction. Random things to do after this course. Course roadmap. CPS 116 Introduction to Database Systems

Introduction. Random things to do after this course. Course roadmap. CPS 116 Introduction to Database Systems Introduction CPS 116 Introduction to Database Systems Random things to do after this course 2 Course roadmap 3 Relational databases Relational algebra, database design, SQL, app programming XML Data model

More information

Index Merging. Abstract. 1. Introduction

Index Merging. Abstract. 1. Introduction Index Merging Surajit Chaudhuri and Vivek Narasayya 1 Microsoft Research, Redmond Email: {surajitc, viveknar}@microsoft.com http://research.microsoft.com/~{surajitc, viveknar} Abstract Indexes play a vital

More information

Introduction to CS 4604

Introduction to CS 4604 Introduction to CS 4604 T. M. Murali August 23, 2010 Course Information Instructor T. M. Murali, 2160B Torgerson, 231-8534, murali@cs.vt.edu Office Hours: 9:30am 11:30am Mondays and Wednesdays Teaching

More information