Skip to main content

Posts

Showing posts from August, 2009

Record Based Logical Models

Record based Logical Models are used in describing data at the conceptual level and view level. They are used to specify the overall logical structure of the database and to provide a higher level description of implementation. Record based models are so called because the database is structured as fixed format records of several types. Each record type defines a fixed number of fields (or attributes) and each field is of fixed length. Record based data models do not include a mechanism for the direct representation of code in the database. But there will be separate languages that are associated with the models to express database queries and update. The three data models are Relational, Network and Hierarchical. RELATIONAL DATA MODEL The relational model represent data and relationship among data by a collection of tables, each of which has a number of columns with unique names. The entities and their relationship(in the ER model) are represented as two-dimensional tables. The mathem

Generalisation and Specialisation

GENERALISATION Consider the account entity set with attributes accno and balance. Each account can be classified as SAVINGS ACCOUNT or CURRENT ACCOUNT. Each of these is described by a set of attributes which include all the attributes of the account entity set PLUS some additional attributes , SAVINGS ACCOUNT entities are described by the attribute INTEREST RATE ,while CURRENT ACCOUNT are described by the attribute OVER DRAFT AMOUNT. There are similarities between the current account entity set and the saving account entity set in the sense that they have several attributes in common . This commonality can be expressed by generalization. Generalization is a containment relationship that exist between a higher level entity set and one or more lower level entity sets .Here the ACCOUNT is the higher level entity and SAVINGS ACCOUNT & CURRENT ACCOUNT are LOWERLEVEL ENTITY SETS. In an ER diagram generalization is represented by a triangular component labeled “ISA" it stands for &qu

Codd's Rule- Fully relatoinal DBMS

CODD’s RULES The founder of the relational data base theory Dr. E F Codd has outlined twelve rules (modified to 333 rules) to test whether a product that is claimed to be fully relational really is an RDBMS. The twelve rules are based on a single foundation principle which is called as rule zero. RULE ZERO : For any system that is claimed to be RDBMS, that system must be able to manage databases entirely through its relational capabilities. RULE ONE Information representation All information in RDB is represented explicitly as values in tables. [ The metadata i.e., table name, column name etc. should also be stored in tables] RULE TWO Guaranteed access Each and every data item (atomic values) in a relational data base is guaranteed to be logically accessible by giving the table name, primary key value and column name. [This rule specifies the need for a primary key to access the data in the data base] RULE THREE Systematic treatment of null values Null values are sup

How to Use DEBUG

DEBUG This tutorial is made to present an overview of the DEBUG.COM program for the IBM PC. This utility can be extremely useful, when used correctly. It is almost a must for Assembler Language programmers, and can also provide an insight into the operation of the machine at the bit level. It has several nice features, including the ability to display and change any of the registers in the IBMPC, start and stop program execution at any time, change the program,and look at diskettes, sector by sector. DEBUG works at the machine code level, but it does also have the ability to disassemble machine code, and (at dos 2.0), assemble instructions directly into machine code. STARTING DEBUG There are two ways to start DEBUG with a file. Both ways produce the same results, and either can be used. In the Command Line: c:\>debug clock.com where clock.com is your executable program Separate from the command line: c:\>debug -n clock.com -l With either method, you will get the DEBUG prompt of a

ER Diagrams to Table

REDUCING E-R DIAGRAM TO TABLE - A database which conforms to an E R diagram can be represented by collection of tables .For each entity set and for each relationship set in the database, we will create unique tables, which is assigned the name of the corresponding entity set or relationship sets . Each table has a no. of columns which have unique names. Each row in the table corresponds to an entity or a relationship. REPRESENTATION OF STRONG ENTITY SET -Let E be a strong entity set with descriptive attributes a1, a2....aN . We represent this entity by table called E with N distinct columns, each of which corresponds to one of the attributes of E. REPRESENTATION OF RELATIONSHIP SET - Let R be a relation ship set involving entity set E1,E2....En Let attribute(R) consists of 'm' attributes We can represent this relation ship set by a table called R with m distinct columns, each of which corresponds to one of the attributes in attribute (R) plus the primary key of E1..En. REPRE

ER Diagrams 2

Roles are indicated in E R diagram by labeling the line that connects diamonds to rectangle. The following figure shows the role indicators MANAGER and the WORKER between the employee entity set and the works for relationship set . A weak entity set is indicated in the E R diagram by doubly outlined box . In the following figure the weak entity set TANSACTION is dependant on the strong entity set ACCOUNT via the relationship set ACC-TRAN Non binary relationship sets can also be represented in ER diagram .Consider the entity set CUSTOMER , ACCOUNT & BRANCH through the relationship CAB. The figure specifies a CUSTOMER may have several account each located in a specific branch of a bank and that an ACCOUNT may belong to several different CUSTOMERS.

ER Diagrams 1

The overall logical structure of a database can be expressed graphically by an ER diagram . It consists of rectangles - which represents entity sets , ellipses - which represents attributes, diamonds - which represents relationship among entity sets and lines which links attributes to entity sets, attributes to relationship sets and entity sets to relationship. Each component is labeled with the entity or relationship or attribute it represents. To distinguish among the four types of mapping cardinalities type, we shall draw either a directed or undirected line segment between the relationship set and the entity set.

Data Models..ER Model

A DBMS uses a data model, as its underlying structure. Data model is a collection of tools for describing data, data relationship, data semantics (meaning) and consistency constraints. Various data models can be classified into three groups. 1. OBJECT BASED LOGICAL MODEL 2. RECORD BASED LOGICAL MODEL 3. PHYSICAL DATA MODEL A data model definition must include the definitions of all possible objects which can be represented by it, all possible operations (insertion, modification, deletion, retrieval etc) which can be performed on these objects, and any rules necessary to preserve the integrity of the data base constructed by it. OBJECT BASED LOGICAL MODELS These are used in describing the data at the conceptual level and view level. Some of the object based logical models are: 1. Entity relationship model 2. Object oriented model 3. Binary model 4. Semantic model 5. Infological model 6. Functional data model 1. Entity relationship model (ER Model) It consists of a collection of basic ob

Data Base Schema and Architecture

DATA A representation of facts, concepts or instructions in a formalized manner suitable for communication, interpretation or processing by human being or by automatic means. Data consists of symbols written or stored on some recording medium. DATA BASE SCHEME (SCHEMA) Schema is a definition of some thing. A database scheme means the over all design of the data base. The database scheme include : 1. Characteristics of data objects such as entities and attributes. 2. Logical structure and relationships among these data objects. 3. Validation criteria and semantic constraints. 4. Physical storage representation (format). 5. Physical location on storage devices and media. 6. Integrity parameters such as access authorizations and back up policies. The database scheme or schema contains all necessary and sufficient information for the system to do all the data base processing. Data base systems have several schemes partitioned according to the levels of abstraction - physical scheme (physic

Introduction to DBMS

DATA BASE SYSTEM Data Base System is a computer based record keeping system whose overall purpose is to record and maintain information. The information can be anything, that is of significance to the organization, the system is serving. ie. anything that may be necessary for the decision making process involved in the management of the organization. A data base system has four major components – data, hardware, software and users. DATA Data stored in the DBS may be partitioned into one or more database. A database is a shared collection of inter-related data designed to meet multiple needs of different types of end users (ordinary user). The data are stored so that they are independent of the programs that use them. A common and controlled approach is used in adding new data and modifying and retrieving existing data. The data in a database is both shared and integrated. By integrated, we mean that the data base may be considered as a unification of several other

Introduction to Data Structures

Visit My Data Structure Blog for Programs... It is important for every Computer Science student to understand the concept of Information and how it is organized or how it can be utilized. If we arrange some data in an appropriate sequence, then it forms a Structure and gives us a meaning. This meaning is called Information . A data structure is a particular way of storing and organizing data in a computer so that it can be used efficiently. Data may be organized in many different ways. The logical model of a particular organization of data in a computer is called data structure. The choice of the model based on two considerations. It should be reflect the data in the real world. It should be simple that one can effectively process the data when necessary. E.g. Array, linked list, stack, queue, tree, graph Data structure can be classified into two: Linear: A data structure is said to be linear if its elements form a sequence E.g. Array, linked list, stack, queue Non-Linear: A dat