Professional Documents
Culture Documents
Database Administrator
The Database Administrator (DBA) who is like the super user of the system.
System Architecture of a DBMS Role of Database administrator: The role of the DBA is very important and is defined by the following functions. Defining the Schema: The DBA defines the schema. Schema contains the structure of the data in the application. The DBA determines what data needs to be present in the system and how this data has to be represented and organized. Liaising with Users: The DBA needs to interact continuously with the users to understand the data in the system and its use. Defining Security & Integrity Checks: The DBA finds about the access restrictions to be defined and defines security checks accordingly. Data Integrity checks are also defined by the DBA. Defining Backup / Recovery Procedures: The DBA also defines procedures for backup and recovery. Defining backup procedures includes specifying what data is to backed up, the periodicity of
taking backups and also the medium and storage place for the backup data. Monitoring Performance: The DBA has to continuously monitor the performance of the queries and take measures to optimize all the queries in the application. Question 2: Write notes about: 1. Physical Storage Structure of DBMS 2. Indexing.
When the DBMS makes a request for a specific record to the File Manager, the latter maps the record to a page containing it and requests the Disk Manager for the specific page. The Disk Manager determines the physical location on the disk and retrieves the required page.
Indexing
Indexing is a common method for making retrievals faster. Consider the example of CUSTOMER table used above. The following query is based on Customer's city. Retrieve the records of all customers
2
who reside in Delhi Here a sequential search on the CUSTOMER table has to be carried out and all records with the value 'Delhi' in the Cust_City field have to be retrieved. The time taken for this operation depends on the number of pages to be accessed. If the records are randomly stored, the page accesses depends on the volume of data. If the records are stored physically together, the number of pages depends on the size of each record also. If such queries based on Cust_City field are very frequent in the application, steps can be taken to improve the performance of these queries. Creating an Index on Cust_City is one such method. This results in the scenario as shown below.
A new index file is created. The number of records in the index file is same as that of the data file. The index file has two fields in each record. One field contains the value of the Cust_City field and the second contains a pointer to the actual data record in the CUSTOMER table. Whenever a query based on Cust_City field occurs, a search is carried out on the Index file. Here, it is to be noted that this search will be much faster than a sequential search in the CUSTOMER table, if the records are stored physically together. This is because of the much smaller size of the index record due to which each page will be able to contain more number of records. When the records with value 'Delhi' in the Cust_City field in the index file are located, the pointer in the second field of the records can be followed to directly retrieve the corresponding CUSTOMER records. Thus the access involves a Sequential access on the index file and a direct access on the actual data file.
Question 3: Write notes about: 1. Three Level Architecture of Database. Database System.
2. Services of a
ensure that only authorized users can have access to the database.
7. Support for data Communication : A DBMS must be able to
that both the data in the database and changes to the data follow certain rules. 9. Services to Promote Data Independence : A DBMS must include facilities to support the independence of programs from the actual structure of the database. 10. Utility Services: A DBMS should provide a set of utility services. Question 4: With a necessary Example Explain: 1. Basic Constructs of E-R Modeling. 2. E-R Notations
E-R Notations
All notational styles represent entities as rectangular boxes and relationships as lines connecting boxes. Each style uses a special set of symbols to represent the cardinality of a connection. The notation used in this document is from Martin. The symbols used for the basic ER constructs are: Entities are represented by labeled rectangles. The label is the name of the entity. Entity names should be singular nouns. Relationships are represented by a solid line connecting two entities. The name of the relationship is written above the line. Relationship names should be verbs. Attributes, when included, are listed inside the entity rectangle. Attributes which are identifiers are underlined. Attribute names should be singular nouns. Cardinality of many is represented by a line ending in a crow's foot. If the crow's foot is omitted, the cardinality is one. Existence is represented by placing a circle or a perpendicular bar on the line. Mandatory existence is shown by the bar (looks like a 1) next to the entity for an instance is required. Optional existence is shown by placing a circle next to the entity that is optional.
Example: