Lesson 1 Database
Lesson 1 Database
manipulate very easily and as when its required. (similar in filing to cabinet). DBMS- is data storage and retrieval system which permits data to store non redundantly while While making it appear to user as if the data will integrated.
2000s
Stream data management and mining. Data mining and its applications. Web technology (XML, data integration) and global information systems.
Database Approach
Self contained nature of database systems (database contains both data and meta-data). Data Independence: application programs and queries are independent of how data is actually stored. Data sharing. Controlling redundancies and inconsistencies. Secure access to database; Restricting unauthorized access. Enforcing Integrity Constraints. Backup and Recovery from system crashes. Support for multiple-users and concurrent access.
Expensive hardware, software, personnel, processing overhead, operating cost , etc. DBMS generality & overhead => performance issue Increased vulnerability to failure Recovery is more complex
Application design n involves designing the user interface and the application programs that use and process the database. This stage involves two main activities: transaction design and user interface design.
Transaction Design
An action, or series of actions, carried out by a single user or application program that accesses or changes the content of the database. There are three main types of transactions:
In addition to designing how the required functionality is to be achieved, we have to design an appropriate user interface for the database system. This interface should present the required information in a user-friendly way.
Prototyping involves building a working model of the database system, which allows the designers or users to visualize and evaluate the system. There are two prototyping strategies in common use today:
Requirements prototyping uses a prototype to determine the requirements of a proposed database system and once the requirements are complete the prototype is discarded. While evolutionary prototyping is used for the same purposes, the important difference is that the prototype is not discarded but with further development becomes the working database system. Implementation is the physical realization of the database and application designs. Data conversion and loading involves transferring any existing data into the new database and converting any existing applications to run on the new database. Testing is the process of running the database system with the intent of nding programming errors. Operational maintenance is the process of monitoring and maintaining the system following installation. The process of monitoring and maintaining the database system following installation. In this stage, the database system now moves into a maintenance stage, which involves the following activities:
Monitoring the performance of the database system. If the performance falls below an acceptable level, the database may need to be tuned or reorganized. Maintaining and upgrading the database system (when required). New requirements are incorporated into the database system through the preceding stages of the lifecycle.
The internal level:- The internal level has an internal schema which describes the physical storage structure of the database. The conceptual level:-The conceptual level has a conceptual schema, it describes the entities, data types, relationships, user operations, and constraints. The external level or view level:- The external or view level includes a number of external schemas or user views. It describes the part of the database that a particular user group is interested in and hides the rest of the database.
Database Language
DDL
For describing data and data structures a suitable description tool, a data definition language (DDL), is needed. With this help a data scheme can be defined and also changed later. Typical DDL operations (with their respective keywords in the structured query language SQL):
Creation of tables and definition of attributes (CREATE TABLE ...) Change of tables by adding or deleting attributes (ALTER TABLE ) Deletion of whole table including content (!) (DROP TABLE )
DML
Additionally a language for the descriptions of the operations with data like store, search, read, change, etc. the so-called data manipulation, is needed. Such operations can be done with a data manipulation language (DML). Within such languages keywords like insert, modify, update, delete, select, etc. are common. Typical DML operations (with their respective keywords in the structured query language SQL):
Add data (INSERT) Change data (UPDATE) Delete data (DELETE) Query data (SELECT)
Database Interface
DBMS Interfaces
Types of interfaces provided by the DBMS include:
Menu-Based Interfaces for Web Clients or Browsing Present users with list of options (menus) Lead user through formulation of request Query is composed of selection options from menu displayed by system.
Forms-Based Interfaces Displays a form to each user. User can fill out form to insert new data or fill out only certain entries. Designed and programmed for nave users as interfaces to canned transactions. Graphical User Interfaces Displays a schema to the user in diagram form. The user can specify a query by manipulating the diagram. GUIs use both forms and menus. Natural Language Interfaces Accept requests in written English, or other languages and attempt to understand them. Interface has its own schema, and a dictionary of important words. Uses the schema and dictionary to interpret a natural language request. Interfaces for Parametric Users Parametric users have small set of operations they perform. Analysts and programmers design and implement a special interface for each class of nave users. Often a small set of commands included to minimize the number of keystrokes required. (I.e. function keys) Interfaces for the DBA Systems contain privileged commands only for DBA staff. Include commands for creating accounts, setting parameters, authorizing accounts, changing the schema, reorganizing the storage structures etc.