Components of DBMS A database management system (DBMS) consists of several components. Each component plays very important role in the database management system environment. The major components of database management system are: Software Hardware Data Procedures Database Access Language Software The main component of a DBMS is the software. It is the set of programs used to handle the database and to control and manage the overall computerized database 1. DBMS software itself, is the most important software component in the overall system 2. Operating system including network software being used in network, to share the data of database among multiple users. 3. Application programs developed in programming languages such as C++, Visual Basic that are used to to access database in database management system. Each program contains statements that request the DBMS to perform operation on database. The operations may include retrieving, updating, deleting data etc . The application program may be conventional or online workstations or terminals. Hardware Hardware consists of a set of physical electronic devices such as computers (together with associated I/O devices like disk drives), storage devices, I/O channels, electromechanical devices that make interface between computers and the real world systems etc, and so on. It is impossible to implement the DBMS without the hardware devices, In a network, a powerful computer with high data processing speed and a storage device with large storage capacity is required as database server. Data Data is the most important component of the DBMS. The main purpose of DBMS is to process the data. In DBMS, databases are defined, constructed and then data is stored, updated and retrieved to and from the databases. The database contains both the actual (or operational) data and the metadata (data about data or description about data). Procedures Procedures refer to the instructions and rules that help to design the database and to use the DBMS. The users that operate and manage the DBMS require documented procedures on hot use or run the database management system. These may include. 1. 2. 3. 4. 5. 6. Procedure to install the new DBMS. To log on to the DBMS. To use the DBMS or application program. To make backup copies of database. To change the structure of database. To generate the reports of data retrieved from database. Database Access Language The database access language is used to access the data to and from the database. The users use the database access language to enter new data, change the existing data in database and to retrieve required data from databases. The user write a set of appropriate commands in a database access language and submits these to the DBMS. The DBMS translates the user commands and sends it to a specific part of the DBMS called the Database Jet Engine. The database engine generates a set of results according to the commands submitted by user, converts these into a user readable form called an Inquiry Report and then displays them on the screen. The administrators may also use the database access language to create and maintain the databases. The most popular database access language is SQL (Structured Query Language). Relational databases are required to have a database query language. Users The users are the people who manage the databases and perform different operations on the databases in the database system.There are three kinds of people who play different roles in database system 1. Application Programmers 2. Database Administrators 3. End-Users Application Programmers The people who write application programs in programming languages (such as Visual Basic, Java, or C++) to interact with databases are called Application Programmer. Database Administrators A person who is responsible for managing the overall database management system is called database administrator or simply DBA. End-Users The end-users are the people who interact with database management system to perform different operations on database such as retrieving, updating, inserting, deleting data etc. File Processing System A File can store records and we can extract these records using different applications programs. The simplest data retrieval task from file require extensive programming. Also this is a time consuming and a high skill activity. To access the data in file the programmer must aware of the physical structure of the file. Security features such as effective password protection, locking parts of file etc are very difficult to program. The File system exhibits structural dependence. That is a change in file structure such as addition or deletion of a field require the modification of all programs using that file. Data dependence: A change in file data characteristic such as change in a field data type from integer to decimal, requires changes in all programs that access the file. A typical file processing system is supported by conventional operating systems. The system stores permanent record in various files. It uses various application programs to extract records from, and add records to the appropriate files. Before using DBMS to store and retrieve data, organizations stored information in file processing systems. But as the number of files in the system expands, system administration becomes difficult too. Each file must have its own file management system, composed of programs that allow user to create the file structure, add data to the file, delete data from the file, modify the data in the file, list the file contents etc. Even a simple file processing system containing 25 files requires 5 * 25 =125 file management programs. Each department in the organization owns its data by creating its own files. So the number of files can multiply rapidly. Security features such as effective password protection, locking out part of files or part of system itself and other data confidentiality measures are difficult to program and are usually omitted. The file system’s structure and lack of security makes it difficult to pool data. The same basic data is stored in different locations. But it is very unlikely that that data stored in different locations will always be updated consistently, hence maintaining different versions of same data. The file processing system is simply not suitable for modern data management and information requirement. Disadvantages of File Processing System The conventional file processing system suffers from the following shortcomings. Data Redundancy Data Inconsistency Difficulty in Accessing Data Data Isolation Integrity Problems Atomicity Problem Concurrent Access anomalies Security Problems Data Redundancy Data Redundancy means same information is duplicated in several files. This makes data redundancy. Data Inconsistency Data Inconsistency means different copies of the same data are not matching. That means different versions of same basic data are existing. This occurs as the result of update operations that are not updating the same data stored at different places. Example: Address Information of a customer is recorded differently in different files. Difficulty in Accessing Data It is not easy to retrieve information using a conventional file processing system. Convenient and efficient information retrieval is almost impossible using conventional file processing system. Data Isolation Data are scattered in various files, and the files may be in different format, writing new application program to retrieve data is difficult Integrity Problems The data values may need to satisfy some integrity constraints. For example the balance field Value must be grater than 5000. We have to handle this through program code in file processing systems. But in database we can declare the integrity constraints along with definition itself. Atomicity Problem It is difficult to ensure atomicity in file processing system. For example transferring $100 from Account A to account B. If a failure occurs during execution there could be situation like $100 is deducted from Account A and not credited in Account B. Concurrent Access anomalies If multiple users are updating the same data simultaneously it will result in inconsistent data state. In file processing system it is very difficult to handle this using program code. This results in concurrent access anomalies. Security Problems Enforcing Security Constraints in file processing system is very difficult as the application programs are added to the system in an ad-hoc manner. Difference between File processing system and DBMS: 1. A database management system coordinates both the physical and the logical access to the data, whereas a file-processing system coordinates only the physical access. 2. A database management system reduces the amount of data duplication by ensuring that a physical piece of data is available to all programs authorized to have access to it, whereas data written by one program in a file-processing system may not be readable by another program. 3. A database management system is designed to allow flexible access to data (i.e., queries), whereas a file-processing system is designed to allow predetermined access to data (i.e., compiled programs). 4. A database management system is designed to coordinate multiple users accessing the same data at the same time. A file-processing system is usually designed to allow one or more programs to access different data files at the same time. In a file-processing system, a file can be accessed by two programs concurrently only if both programs have read-only access to the file. 5. Redundancy is control in DBMS, but not in file system 6. Unauthorized access is restricted in DBMS but not in file system. 7. DBMS provide back up and recovery. When data is lost in file system then it not recover. 8. DBMS provide multiple user interfaces. Data is isolated in file system, Database Administrator [DBA] Definition Centralized control of the database is exerted by a person or group of persons under the supervision of a high level administrator. This person or group is referred to as the database administrator (DBA). They are the users who are most familiar with the database and are responsible for creating, modifying, and maintaining its three levels. Database Administrator is responsible to manage the DBMS’s use and ensure that the database is functioning properly. DBA administers the three levels of database and consultation with the overall user community, sets up the definition of the global view of the various users and applications and is responsible the definition and implementation of the internal level, including the storage structure and access methods to be used for the optimum performance of the DBMS. DBA is responsible for granting permission to the users of the database and stores the profile of each user in the database. Responsibilities of DBA Deciding the information content of the database It is the DBA’s job to decide exactly what information is to be held in the database - in other words, to identify the entities of interest to the enterprise and to identify the information to be recorded about those entities. Having done this, the DBA must then define the content of the database by writing the conceptual schema. … Deciding the storage structure and access strategy The DBA must also decide how the data is to be represented in the database, and must specify the representation by writing the storage structure definition. In addition, the associated mapping between storage structure definition and the conceptual schema must also be specified. … Liaising with the users It is the business of the DBA to liaise with users, to ensure that the data they require is available, and to write the necessary external schemas. In addition, the mapping between any given external schema and the conceptual schema must also be specified. In practice the external DDL will probably include the means for specifying the mapping, but the schema and the mapping should be clearly distinguishable. Defining authorization checks and validation procedures Authorization checks and validation procedures may be considered as logical extensions of the conceptual schema. The conceptual DDL will include facilities for specifying such checks and procedures. … Defining a strategy for backup and recovery Once an enterprise is committed to a database, it become critically dependent on the successful operation of that system. In the event of damage to any portion of the database – caused by human error, say, or a failure in the hardware or supporting operating system – it is essential to be able to repair the data concerned with a minimum of delay and with as little effect as possible on the rest of the system. Monitoring performance and responsibilities to changes in requirements The DBA is responsible for so organizing the system as to get the performance that is “best for the enterprise” and for making the appropriate adjustments change. Any change to details of storage and access must be accompanied by a corresponding change to the definition of the mapping to storage, so that the conceptual schema may remain constant.