• No results found

CHARACTERISTICS OF DATA IN A DATABASE

In document MIS Study Material 2009 (Page 103-106)

Srinivas MBA : MIS : CH 4   2009

CHARACTERISTICS OF DATA IN A DATABASE

The data in a database should have the following features.

1. Shared - Data in a database are shared among different users and applications.

2. Persistence - Data in a database exist permanently in the sense, the data can live beyond the scope of the process that created it.

Srinivas MBA : MIS : CH 4   2009 

102

3. Validity/Integrity/Correctness - Data should be correct with respect to the real world entity that they represent.

4. Security - Data should be protected from unauthorized access.

5. Consistency - Whenever more than one data element in a database represents related real-world values, the values should be consistent with respect to the relationship.

6. Non-redundancy - No two data items in a database should represent the same real-world entity.

7. Independence - The three levels in the schema (internal, conceptual and external) should be independent of each other so that the changes in the schema at one level should not affect the other levels.

File Pointers :

File pointers establish linkage between records and are a basic part of the file organization of all data base models except the relational model. A pointer is placed in the last field of record. A pointer is the address of another, related record that is “pointed to” and the pointer directs the computer system to that related record. File pointers are used with many database organizations.

Linked Lists :

A linked list is a group of data records arranged in an order, which is based on embedded pointers. An embedded pointer is a specific data field that links one record to another by referring to the other record. The field is embedded in the first record, i.e., it is a data element within the record.

Linked list often have a head, which is a pointer to the first record. It has a tail, which points to the last record. One can start at head and follow the list to the tail, or one can start in the middle and follow the list to the tail. The user can not start in the middle and go back to the head. In other words, the linked list is a one-way street.

The following figure shows a linked list of customer records. Each row is a record. The records are arranged sequentially using customer number as the key. Each record includes a data element, which identifies assigned salesperson.

In the right most field of record there is a pointer (a link) that chains together all customers records for a particular salesperson say salesperson 23. It can be assumed that customer 23694 is at the head of the list. The pointer links this record to a record for customer 25410 and so on until the tail for customer 30111 is encountered. The asterisk in the link indicates the tail of the list.

This chaining feature is very powerful. The application program can initiate a search at the beginning of the file looking for first customer assigned to salesperson 23. When that record is found, the salesperson links enable the program to follow the chain and process records only for salesperson 23. It is more convenient method than searching through the entire file.

Srinivas MBA : MIS : CH 4   2009 

103

Customer Salesperson

Number

Salesperson link\

22504

23694 23 25410

24782 25409

25410 23 30102

26713 28914 30004

30102 23 30111*

30111 23 30417 31715

Components of DBMS

A DBMS has 3 main components (a) Data dictionary system (DDS) (b) Data definition language (DDL) (c) Data manipulation language (DML)

(a) Data dictionary system (DDS) : The data dictionary system is an encyclopedia of information concerning each data element. It describes the data and its characteristics, such as location, size and data type. It also identifies the origin, use, ownership and also the methods of data access and data security.

When it exists in a file, special software is necessary to create it, maintain it and make it available for use. Such software is called a data dictionary system. A good data dictionary would ensure consistent definitions of data across different databases. If there were to be a change to the data, it would also identify all the databases affected by the change.

(b) Data Definition Language (DDL) : The data definition language is used to create the data, describe the data and define the schema in the DBMS. It serves as an interface for application programs that use the data. Once the data dictionary has been created, its definitions must be entered into the DBMS. The primary functions of DDL are :

1. Describes the schema and subschemas.

2. Describes the fields in each record and record’s logical name.

Srinivas MBA : MIS : CH 4   2009 

104

3. Describe the data type and name of each field.

4. Indicate the keys of the record.

5. Provide for data security restrictions.

6. Provide for logical and physical data independence.

7. Provide means for associating related records or fields.

For example, if a payroll program needs the employment number of an employee, the DDL defines the logical relationship between the employment number and the other data in the database, and acts as an interface between the payroll program and the files that contain the employment numbers.

(c) Data Manipulation Language (DML) : A data manipulation language is a language that processes and manipulates the data in the database. It also allows the user to query the database and receive summary reports and / or customized reports. DML enables the user to access, update, replace, delete and protect database records from unauthorized access.

The functions of DML are :

1. Provide techniques for data manipulation such as deletion, replacement, retrieval, sorting, or insertion of data or records.

2. Allows user and application programs to process data on logical basis rather than physical location basis.

3. Provide access which is independence of programming languages.

4. Provide for use of record relationships.

In document MIS Study Material 2009 (Page 103-106)