Relational Database Management System [DBMS]

Leave a Comment

The arrangement of data in the form of records and fields is called a database

Database Management System: The DBMS is the management of databases in the form of a package.

Features:
  1. Creating Tables
  2. Entering database records
  3. Sorting
  4. Deleting
  5. Updating
  6. Merging Database files
  7. Copying
  8. Printing
  9. Validating
  10. Converting
  11. Generating Reports

Relational Database Model

Arranging of data in a logical way in the form of table of showing relationship between different fields.

Terms used in RDBMS
  1. Entity:- Is a person, place, event or thing
  2. Attributes:- Characteristic of an entity is known as attribute
  3. Relation:- It shows relation between any two entities
  4. Tuple:- Row of a relation
  5. Domain:- Values of attributes or column
  6. Degree:- Relationship degree indicate number of associated entities.

Types of relationships
  1. Urnary
  2. Binary
  3. Ternary

Relational Algebra

It define theoretical way of manipulating table contents using the eight relational functions.
  1. SELECT
  2. PROJECT
  3. JOIN
  4. INTERSECTION
  5. UNION
  6. DIFFERENCE
  7. PRODUCT
  8. DIVIDE

  • UNION: Combine all rows from two tables
  • Intersection: Produce a listing that contain only rows that appear in both tables.
  • Difference: Yields all rows in one table that are not found in other table
  • Cartesian product: Produces a list of all possible pair of rows from two tables
  • Select: Yields values for all attributes found in a table
  • Project: Produces list of all values for selected attributes
  • Join: Allows to combine information from two or more tables
  • Divide: Divide the table into separate tables based on its columns

E – R Diagrams

The overall logical structure of a database can be expressed graphically by an E–R diagram.

E–R diagram consist of following components

E-R diagram of part of project- management system
E-R diagram of part of project- management system

Cardinality: 
The number mentioned on the relation shows types of relationship
  1. one–one
  2. one–many
  3. many–one
  4. many–many

Key

Common attributes that enable us to link tables, such attributes are called keys.

Types of Keys:

  1. Super key: An attribute that uniquely identifies each entity in a table.
  2. Candidate key: A minimal super key that does not contain a subset of attributes that is itself a super key.
  3. Primary key: A candidate key selected to uniquely identify all other attribute values in any given row cannot contain null entries.
  4. Secondary key: An attribute used strictly for data retrieval purpose
  5. Foreign key: An attribute in one table whose values must either match the primary key in another table to be null.

Tuple Calculus

It is a special case of language of the semantical system consider semantic system in following form ∑i.

i = < Ri U C, {Φ, R, S,-------}, Φ, R, S,------- >

where, Ri = the set of real numbers.
           C = set of character strings of finite length
           { Φ, R, S,-------} = set of relational symbols.

Atomic wff of i

  1. R(t) is an atomic wff of ∑i if R is a relation symbol and t is a R – string whose components are in Ri U C
  2. Φ u [i] v [j] this is written as u [i] Φ v [j] is an atomic wff of i provided that u and v are both R – strings or one is a R – string and other is a S – string where R and S are two relation symbols of ∑i

Quasi – wff
Ψ is a quasi quantifier ∑i if

  1. Ψ is an atomic wff of ∑i or
  2. Any expression of Ψ obtained from Ψ by substituting constants of ∑i for the placeholders used in Ψ, is an atomic wff of  i .
  3. 1 V Ψ2) is a quasi wff if Ψ1  and Ψ2 are Quasi – wff and no place holder I in both free in Ψ1 and bound in Ψ2 or vice versa.
A wff is a quasi w f f in which no place holder is free.

Safe Expressions
A tuple calculus expressions {t/ Ψ(t)} is said to be a safe expression provided following conditions hold good

  1. All components of each t that makes y true are in DOM (Ψ).
  2. If there is a quasi – wff of the form (for all s) (W(s)) in Ψ then all the components of that u which make W (with possible values of other free variables in w).
  3. If Ψ has within itself a quasi – wff of the form (for all s) (W(s)) then the components of all Ss irrespective of the fact that whether w is satisfied by these or not must be DOM(Ψ).

0 comments:

Post a Comment