06 Database

You might also like

Download as pdf or txt
Download as pdf or txt
You are on page 1of 16

DATABASE

CONTENTS
1. Introduction
2. DBMS Basic
3. SQL Basic
4. No SQL
5. In Memory Cache Database
6. High Availability
INTRODUCTION

DBMS (Database Management System) is an application software to manage the database of an


organization.

DBMS are two types

1. RDBMS

2. No SQL
COMPONENTS OF A DATABASE SYSTEM
RDBMS
RDBMS means relational database management system

1. It is A collection of files that store the data

2. A big C program written by someone else that accesses and updates those files for you

Examples : Oracle, DB2, SQL Server, Mysql


KEY TERMS

 An entity is something of importance to a user that needs to be represented in a database


 An entity represents one theme or topic and is represented by a table.
 The table dimensions, like a matrix, consist of rows (tuples) and columns (attributes)
KEYS IN DBMS
A (primary) key is one (or more) columns of a relation that is (are) used to identify a row

A composite key is a key that contains two or more attributes

For a key to be unique, it is sometimes necessary to use a composite key

Can also generate a set of unique values to serve as the key (for example University ID numbers)
SQL
SQL stands for structured query language. It is the universal language to interact with the
database server for all kind of RDBMS.

It is divided into 3 parts:

1. DDL - Data Definition Language


2. DML - Data Manipulation Language
3. DCL - Data Control Language
Table name Attribute names

Tables in SQL

Tuples or rows
SIMPLE QUERY IN SQL
Product

SELECT PName, Price, Manufacturer


FROM Product
WHERE Price > 100

“selection” and
“projection”
NoSQL
 It Stands for No-SQL or Not Only SQL Class of non-relational data storage systems
Example: BigTable, Dynamo, PNUTS/Sherpa
 Usually do not require a fixed table schema nor do they use the concept of joins
 Distributed data storage systems All NoSQL offerings relax one or more of the ACID properties that is
Cap Theorem
Examples: Mongo DB, Couch DB, Apache Cassendra etc.
COMMON ADVANTAGES OF NOSQL SYSTEMS
 Cheap, easy to implement (open source)
 Data are replicated to multiple nodes (therefore identical and fault-tolerant) and can be
partitioned When data is written, the latest version is on at least one node and then replicated
to other nodes
 No single point of failure Easy to distribute
 Don't require a schema
LIMITATION OF NOSQL
 Joins
 Group by
But PNUTS provides interesting materialized view approach to joins/aggregation
 ACID transactions
 Integration with applications that are based on SQL
IN MEMORY CACHE DATABASE
Oracle In-Memory Database Cache is an Oracle Database product option ideal for caching a
performance-critical subset of an Oracle database in the application tier for improved response time.

Applications perform read/write operations on the cache tables using SQL, PL/SQL with automatic
persistence, transactional consistency, and data synchronization with the Oracle database. Oracle In-
Memory Database Cache is built using the Oracle Times Ten In-Memory Database product.
HIGH AVAILBILITY
A database system is highly available if it remains accessible to its users in the face of hardware
failures

High availability (HA) is becoming a requirement for almost all database applications, not just
mission critical ones

Maintaining database consistency in the face of failure


Minimizing the impact on performance during normal operation and after a failure
Reducing the complexity and administrative overhead of HA
THANK YOU

You might also like