Вы находитесь на странице: 1из 5

RDBMS QUESTION BANK UNIT TEST 1 Q.1 Explain the advantages of DBMS over the file processing system.

Ans. The advantages of DBMS are as follows: 1. Data Sharing: Through the use of DBMS number of users can share data among themselves. It means that it is possible to satisfy data requirements of new applications without having to add any new data to the database. 2. Reduction of redundant data: Unnecessary duplication of data wasting precious storage space of database is reduced efficiently by the DBMS. 3. Data Security: Unauthorized access to centralized and confidential data in the database is controlled efficiently by DBMS, by applying proper authentication schemes to the users of the database. 4. Data consistency: We can maintain the consistency in the database by successful reduction of redundant data in the database by the DBMS. Q.2 State four applications of DBMS. Ans. Applications of DBMS are as follows: 1. 2. 3. 4. Universities: for Student information, course details and grades. Air Lines and Railway reservation system: For Reservation and information scheduling. Banking: For costumer information, accounts, and banking transactions. Human Resource: For information about employees, salaries, payroll taxes, benefits and for generation of pay checks.

Q.3 Explain functions of DBA. Ans. Functions of DBA (Database Administrator) are as follows: 1. Granting authorization for data access: The DBA is responsible for granting various authorization to different types of users for accessing data from the database. 2. Integrity constraint specification: Constraints are kept in special system structure and are checked each time there is any modification taking place in the database. 3. To participate in Database and Application Development: The DBA normally is a key member in requirements stage and data model creation. It plays and important role in database design. 4. To facilitate changes to Database Structure: The DBA provides configuration control form, accesses the impact of changes on all users and seeks country wide solutions for database structure changes. Q.4 What is instance and schema? Ans. Instance: The collection of information stored in the database of a particular moment is called as an instance. The values of the variables declared in the program are corresponding to the instance. Schema: The overall design of the database is known as schema. A database schema is related with the variables which are declared in the program.

Q.5 Explain two types of Data independence. Ans. Data independence :The capacity to change the schema definition at one level of a database system without having to change the schema definition of the next higher level is called as data independence. There are two types of Data independence :

1. Logical Data Independence :It is the capacity to change the conceptual schema without having the change external schemas or application programs. There is a need for making changes in the conceptual schema so as to suffice the need for expanding the database, to change constrains or to reduce the databse. 2. Physical Data Independence :It is the capacity to change the internal schema without having to change the conceptual schema and the external schemas.Cahnges to the internal schema may be needed basue some physical files had to be reorganized. Q.6 Explain Storage Manager Component of DBMS Architecture. Ans. A Storage manager is a program or module that provides the interface bebtween the lower level data stored in the database, application programs and queries submitted to the system. Storage Manager Components are as follows: 1. Authorization and Integrity manager: The major function of this component is to check the integrity constraint and check the authority of the user access to the data.Another functions is to check the authorities of the users to access, retrieve or update the data from or to the database. 2. Transaction Manager : A transactions is collection of operations that perform a single logical function in a database application.Transaction Manager ensures that the database will be consistent even though the system fails. 3. File Manager : File manager manages the allocation of the space on disk.It allocates the required space to the files which are stored on the storage disk. 4. Buffer Manager : Buffer Manager manages the transfer of the data from the disk to the main memory. Q.7 Explain three-tier architecture of Client server architecture. Ans. Three Tier Client Server Architecture : A Three Tier Client Server Application Architecture separates the user interface,the data logic and the database server onto three separate tiers. Generally this means that there are three computers involved,though it is possible to program the application so that the data logic partruns as an independent process on either the client or server computer. A Multi Tier,oftenreffered to as Three Tier or n Tier,architecture provides greater application scalability, lower maintainence and increased reuse of components. Three tier architecture offers a technology neutral method of building client server applications with vendors who employ standard interfaces which provde services for each logical tier.

Q.8 Explain Codds Rules for fully functional RDBMS.(Any 4) Ans. The rules are as follows: 1. The information Rule : all information in a relational database including table and column names is represented in only one way, namely as a value in a table. 2. The view updating rule: All views that are theoretically updatable must be updaable by the system. 3. Physical Data independence : Changes to the physical level must not require a change to an application based on the structure. 4. The nonsubversion rule: If the system provides a low-level interface,then that interface cannot be used to subvert the system, for example,bypassing a relational security or integrity constraint. Q.9 What is data warehousing?

Ans. A relational Database that is designed for query and analysis, rather than for transaction processing is called as datawarehouse. It usually contains older data derived from transaction data,but can include data from any other sources. It separates analysis workload from transaction processing workload. Q.10 Explain Distributed Database with two types. Ans. A distributed database is a database in which storage devices are not all attached to a common processing unit such as the CPU controlled by a distributed DBMS sometimes called a distributed database system). It may be stored in multiplecomputers, located in the same physical location; or may be dispersed over a network of interconnected computers. Types of Distributed Database systems : Homogeneous DDBMS

In a homogeneous distributed database all sites have identical software and are aware of each other and agree to cooperate in processing user requests. Each site surrenders part of its autonomy in terms of right to change schema or software. A homogeneous DDBMS appears to the user as a single system. The homogeneous system is much easier to design and manage. The following conditions must be satisfied for homogeneous database: The operating system used, at each location must be same or compatible. The data structures used at each location must be same or compatible. The database application (or DBMS) used at each location must be same or compatible. -

Heterogeneous DDBMS

In a heterogeneous distributed database different sites may use different schema and software. Difference in schema is a major problem for query processing and transaction processing. Sites may not be aware of each other and may provide only limited facilities for cooperation in transaction processing. In heterogeneous systems, different nodes may have different hardware & software and data structures at various nodes or locations are also incompatible. Different computers and operating systems, database applications or data models may be used at each of the locations. For example, one location may have the latest relational database management technology, while another location may store data using conventional files or old version of database management system. Similarly, one location may have the Windows NT operating system, while another may have UNIX. Heterogeneous systems are usually used when individual sites use their own hardware and software. Q,11 Explain primary key with example. Ans. A primary key is a column (or columns) in a table that uniquely identifies the rows in that table. CUSTOMERS CustomerNoFirstNameLastName 1 2 Sally Sally Thompson Henderson

3 4

Harry Sandra

Henderson Wellington

For example, in the table above, CustomerNo is the primary key.The values placed in primary key columns must be unique for each row: no duplicates can be tolerated. In addition, nulls are not allowed in primary key columns. Q.12 Explain Hierarchical Model, Network model and relational model. Ans. Hierarchical Model A hierarchical database model is a data model in which the data is organized into a tree-like structure. The structure allows representing information using parent/child relationships: each parent can have many children, but each child has only one parent (also known as a 1-to-many relationship). All attributes of a specific record are listed under an entity type. Network Model The network model is a database model conceived as a flexible way of representing objects and their relationships. Its distinguishing feature is that the schema, viewed as a graph in which object types are nodes and relationship types are arcs, is not restricted to being a hierarchy or lattice. Relational Model (RDBMS - relational database management system) A database based on the relational model developed by E.F. Codd. A relational database allows the definition of data structures, storage and retrieval operations and integrity constraints. In such a database the data and relations between them are organised in tables. A table is a collection of records and each record in a table contains the same fields. Q.13 Explain Domain Integrity constraints with example. Ans. Domain Integrity constraints is used to maintain value according to the user specifications. Thjis integrity aconstraint is enforced on the column levfel and hence the name domain intergrity constraint. There are 2 types of Domain Integrity constraints: 1. Not Null Constraints :The NOT NULL constraint enforces a column to NOT accept NULL values.The NOT NULL constraint enforces a field to always contain a value. This means that you cannot insert a new record, or update a record without adding a value to this field. 2. Check Constraints :The CHECK constraint is used to limit the value range that can be placed in a column.If you define a CHECK constraint on a single column it allows only certain values for this column.If you define a CHECK constraint on a table it can limit the values in certain columns based on values in other columns in the row.

Q.14 Explain DDL Commands with example. Ans. Data Definition Language deals with database schemas and descriptions of how the data should reside in the database, therefore language statements like CREATE TABLE or ALTER TABLE belong to DDL. DML deals with data manipulation, and therefore includes most common SQL statements such SELECT, INSERT, etc. Data Control Language includes commands such as GRANT, and mostly concerns with rights, permissions and other controls of the database system. Data Definition Language (DDL) statements are used to define the database structure or schema. CREATE - to create objects in the database ALTER - alters the structure of the database DROP - delete objects from the database TRUNCATE - remove all records from a table, including all spaces allocated for the records are removed COMMENT - add comments to the data dictionary RENAME - rename an object

(Saayeel K.)