-->

Sunday, December 14, 2014

DATABASE MANAGEMENT SYSTEM for Competitive Exams






DBMS is the acronym of Data Base Management System. DBMS is a collection of interrelated data and a set of programs to access this data in a convenient and efficient way. It controls the organization, storage, retrieval, security and integrity of data in a database. Architecture of DBMS The generalized architecture of DBMS is called ANSI/ SPARC model.

The architecture is divided into three levels:

1. External view or user view/View Level It is the highest level of data abstraction. This includes only those portions of database of concern to a user or Application program. Each user has a different external view and it is described by means of a scheme called external schema.

2. Conceptual view/Logical Level All the database entities and the relationship among them are included. One conceptual view represents the entire database called conceptual schema.

3. Internal view/Physical Level It is the lowest level of abstraction, closest to the physical storage method. It describes how the data is stored, what is the structure of data storage and the method of accessing these data. It is represented by internal schema. View Level … Defined by User

Data model: A data model is a plan for building a database. The model represents data conceptually, the way the user sees it, rather than how computers store it. Data models focus on required data elements and associations.

1. Entity – Relationship Model 2. Relational Model

Entity: A thing (animate or inanimate) of independent physical or conceptual existence and distinguishable. In the University database context, an individual student, faculty member, a class room, a course are entities.

Attributes

Each entity is described by a set of attributes/properties. 

Types of Attributes

---Simple Attributes: having atomic or indivisible values: Dept – a string Phone Number – an eight digit number.

---Composite Attributes: having several components in the value. Example: Qualification with components (Degree Name, Year, University Name)

---Derived Attributes: Attribute value is dependent on some other attribute. Example: Age depends on Date of Birth. So age is a derived attribute.

---Single-valued: having only one value rather than a set of values. For instance, Place of Birth-single string value.

---Multi-valued: having a set of values rather than a single value, for instance, Courses Enrolled attribute for student Email Address attribute for student Previous Degree attribute for student.

Attributes can be: simple single-valued, simple multi-valued, composite single-valued or composite multi-valued.

NOTE: Diagrammatic Notation for Entities entity – rectangle attribute – ellipse connected to rectangle multi-valued attribute – double ellipse composite attribute- ellipse connected to ellipse

Keys in DBMS:

►A super key of an entity set is a set of one or more attributes whose values uniquely determine each entity.

►A candidate key of an entity set is a set of fields from which primary key can be selected. It is an attribute or a set of attributes that can act as a primary key for a table to uniquely identify each record in a table.

Although several candidate keys may exist, one of the candidate keys is selected to be the primary key.


Primary key is a candidate key that is most appropriate to become main key of the table. It is a key that uniquely identifies each record in the table. 

No comments:

Post a Comment