Databases & Database Users Dr Fawaz Alarfaj Al Imam Mohammed Ibn Saud Islamic University ACKNOWLEDGEMENT Slides are adopted from: Elmasri & Navathe, Fundamentals of Database Systems Types of Databases and Database Applications Traditional Applications: Numeric and Textual Databases More Recent Applications: Multimedia Databases Geographic Information Systems (GIS) Biological and Genome Databases Data Warehouses Mobile databases Real-time and Active Databases قسم علومم االحاسب وواالمعلوماتت - كلية االشريعة وواالدررااساتت االاسلامية بالاحساءء 2 Recent Developments New Technologies are emerging from the so-called non-database software vendors to manage vast amounts of data generated on the web: Big Data storage systems involving large clusters of distributed computers NoSQL (Not Only SQL) systems A large amount of data now resides on the cloud which means it is in huge data centres using thousands of machines. قسم علومم االحاسب وواالمعلوماتت - كلية االشريعة وواالدررااساتت االاسلامية بالاحساءء 3
Impact of Databases and Database Technology Businesses: Banking, Insurance, Retail, Transportation, Healthcare, Manufacturing Service Industries: Financial, Real-estate, Legal, Electronic Commerce, Small businesses Education: Resources for content and Delivery More recently: Social Networks, Environmental and Scientific Applications, Medicine and Genetics Personalised Applications: based on smart mobile devices قسم علومم االحاسب وواالمعلوماتت - كلية االشريعة وواالدررااساتت االاسلامية بالاحساءء 4 Simplified database system environment قسم علومم االحاسب وواالمعلوماتت - كلية االشريعة وواالدررااساتت االاسلامية بالاحساءء 5 Typical DBMS Functionality Define a particular database in terms of its data types, structures, and constraints Construct or Load the initial database contents on a secondary storage medium Manipulating the database: Retrieval: Querying, generating reports Modification: Insertions, deletions and updates to its content Accessing the database through Web applications Sharing by a set of concurrent users and application programs yet, keeping all data valid and consistent قسم علومم االحاسب وواالمعلوماتت - كلية االشريعة وواالدررااساتت االاسلامية بالاحساءء 6
Additional DBMS Functionality Protection provide Security measures to prevent unauthorised access Presentation data visualisation and reporting Maintenance of the database and associated programs over the lifetime of the database application قسم علومم االحاسب وواالمعلوماتت - كلية االشريعة وواالدررااساتت االاسلامية بالاحساءء 7 Application Activities Against a Database Applications interact with a database by generating Queries: that access different parts of data and formulate the result of a request Transactions: that may read some data and update certain values or generate new data and store that in the database قسم علومم االحاسب وواالمعلوماتت - كلية االشريعة وواالدررااساتت االاسلامية بالاحساءء 8 Application Activities Against a Database Applications should obligate to the following rules: Applications must not allow unauthorised users to access data Applications must keep up with changing user requirements against the database قسم علومم االحاسب وواالمعلوماتت - كلية االشريعة وواالدررااساتت االاسلامية بالاحساءء 9
Example of a Database Mini-world for the example: Part of a UNIVERSITY environment. Some mini-world entities: STUDENTs COURSEs SECTIONs (of COURSEs) (academic) DEPARTMENTs INSTRUCTORs قسم علومم االحاسب وواالمعلوماتت - كلية االشريعة وواالدررااساتت االاسلامية بالاحساءء 10 What other approaches to access and manipulate data? قسم علومم االحاسب وواالمعلوماتت - كلية االشريعة وواالدررااساتت االاسلامية بالاحساءء 11 File Processing Approach vs. the File Processing Approach Each Program has its own set of files High in data redundancy High in data isolation Data access issues Each Program/user share data Low data redundancy Promotes data sharing Easer data access Can be more vulnerable قسم علومم االحاسب وواالمعلوماتت - كلية االشريعة وواالدررااساتت االاسلامية بالاحساءء 12
Main Characteristics of the 1. Self-describing nature of a database system: A DBMS catalog stores the description of a particular database (e.g. data structures, types, and constraints) The description is called meta-data*. This allows the DBMS software to work with different database applications. قسم علومم االحاسب وواالمعلوماتت - كلية االشريعة وواالدررااساتت االاسلامية بالاحساءء 13 Main Characteristics of the 1. Self-describing nature of a database system قسم علومم االحاسب وواالمعلوماتت - كلية االشريعة وواالدررااساتت االاسلامية بالاحساءء 14 Main Characteristics of the 2. Insulation between programs and data: Program-data independence. Allows changing data structures and storage organisation without having to change the DBMS access programs. قسم علومم االحاسب وواالمعلوماتت - كلية االشريعة وواالدررااساتت االاسلامية بالاحساءء 15
Main Characteristics of the 3. Data Abstraction: A data model is used to hide storage details and present the users with a conceptual view of the database. Programs refer to the data model constructs rather than data storage details قسم علومم االحاسب وواالمعلوماتت - كلية االشريعة وواالدررااساتت االاسلامية بالاحساءء 16 Main Characteristics of the 4. Support of multiple views of the data: Each user may see a different view of the database, which describes only the data of interest to that user. قسم علومم االحاسب وواالمعلوماتت - كلية االشريعة وواالدررااساتت االاسلامية بالاحساءء 17 Main Characteristics of the 4. Support of multiple views of the data: قسم علومم االحاسب وواالمعلوماتت - كلية االشريعة وواالدررااساتت االاسلامية بالاحساءء 18
Main Characteristics of the 5.Sharing of data and multi-user transaction processing: Allowing a set of concurrent users to retrieve from and to update the database. Concurrency control within the DBMS guarantees that each transaction is correctly executed or aborted. قسم علومم االحاسب وواالمعلوماتت - كلية االشريعة وواالدررااساتت االاسلامية بالاحساءء 19 Main Characteristics of the 5.Sharing of data and multi-user transaction processing: Recovery subsystem ensures each completed transaction has its effect permanently recorded in the database OLTP (Online Transaction Processing) is a major part of database applications. This allows hundreds of concurrent transactions to execute per second. قسم علومم االحاسب وواالمعلوماتت - كلية االشريعة وواالدررااساتت االاسلامية بالاحساءء 20 IS371 (2017) قسم علومم االحاسب وواالمعلوماتت - كلية االشريعة وواالدررااساتت االاسلامية بالاحساءء 21
Users may be divided into Actors on the Scene Those who actually use and control the database content, and those who design, develop and maintain database applications Workers Behind the Scene Those who design and develop the DBMS software and related tools, and the computer systems operators 22 قسم علومم االحاسب وواالمعلوماتت - كلية االشريعة وواالدررااساتت االاسلامية بالاحساءء Actors on the Scene 1. Database Administrators: Responsible for: Authorising access to the database Coordinating & monitoring its use Acquiring software & hardware resources Controlling its use Monitoring efficiency of operations 23 قسم علومم االحاسب وواالمعلوماتت - كلية االشريعة وواالدررااساتت االاسلامية بالاحساءء Actors on the Scene 2. Database Designers: Responsible to: Define the content, the structure, and the constraints. Define the functions or transactions against the database. Communicate with the end-users and understand their needs. 24 قسم علومم االحاسب وواالمعلوماتت - كلية االشريعة وواالدررااساتت االاسلامية بالاحساءء
Actors on the Scene 3. End-users: They use the data for queries, reports and some of them update the database content. End-users can be categorised into: 3.1. Casual: access database occasionally when needed 3.2. Naïve or Parametric: they make up a large section of the end-user population They use previously well-defined functions Users of Mobile Apps mostly fall in this category Bank-tellers or reservation clerks are parametric users Social Media Users post and read information from websites 25 قسم علومم االحاسب وواالمعلوماتت - كلية االشريعة وواالدررااساتت االاسلامية بالاحساءء Actors on the Scene 3. End-users: 3.3. Sophisticated: Include business analysts, scientists, engineers, others thoroughly familiar with the system capabilities. 3.4. Stand-alone: Mostly maintain personal databases using ready-touse packaged applications. قسم علومم االحاسب وواالمعلوماتت - كلية االشريعة وواالدررااساتت االاسلامية بالاحساءء 26 Actors on the Scene 3. End-users: Please go to the quiz at course webpage قسم علومم االحاسب وواالمعلوماتت - كلية االشريعة وواالدررااساتت االاسلامية بالاحساءء 27
Actors on the Scene 4. IT workforce 4.1. System Analysts: They understand the user requirements and design applications to meet those requirements. 4.2. Application Programmers: Implement the specifications developed by analysts and test and debug them before deployment. 4.3. Business Analysts: Analyse vast amounts of business data for decision making related to planning, advertising, marketing etc. قسم علومم االحاسب وواالمعلوماتت - كلية االشريعة وواالدررااساتت االاسلامية بالاحساءء 28 Actors Behind the Scene 1.System Designers and Implementors: Design and implement DBMS packages in the form of modules and interfaces and test and debug them. The DBMS must interface with applications, language compilers, operating system components, etc. قسم علومم االحاسب وواالمعلوماتت - كلية االشريعة وواالدررااساتت االاسلامية بالاحساءء 29 Actors Behind the Scene 2.Tool Developers: Design and implement software systems called tools for modelling and designing databases, performance monitoring, prototyping, test data generation, user interface creation, simulation etc. قسم علومم االحاسب وواالمعلوماتت - كلية االشريعة وواالدررااساتت االاسلامية بالاحساءء 30
Actors Behind the Scene 3.Operators and Maintenance Personnel: They manage the actual running and maintenance of the database system hardware and software environment. قسم علومم االحاسب وواالمعلوماتت - كلية االشريعة وواالدررااساتت االاسلامية بالاحساءء 31 Advantages of Using the 1. Controlling redundancy in data storage and in development and maintenance efforts. Sharing of data among multiple users. 2. Restricting unauthorised access to data. Only the DBA staff uses privileged commands and facilities. 3. Providing persistent storage for program Objects Object-oriented DBMSs make program objects persistent 4. Providing Storage Structures (e.g. indexes) for efficient Query Processing قسم علومم االحاسب وواالمعلوماتت - كلية االشريعة وواالدررااساتت االاسلامية بالاحساءء 32 Advantages of Using the 5. Providing backup and recovery services. What happen if the power shut down in the middle of complex update transaction? 6. Providing multiple interfaces to different classes of users. different access levels to the same data (mobile, UGI, programatic, etc). 7. Representing complex relationships among data. 8. Enforcing integrity constraints on the database. e.g., specifying data types, referential integrity, key قسم علومم االحاسب وواالمعلوماتت - كلية االشريعة وواالدررااساتت االاسلامية بالاحساءء 33
Implications of Using the Potential for enforcing standards: This is very crucial for the success of database applications in large organisations. Standards refer to data item names, display formats, screens, report structures, meta-data (description of data), Web page layouts, etc. Reduced application development time: Incremental time to add each new application is reduced. قسم علومم االحاسب وواالمعلوماتت - كلية االشريعة وواالدررااساتت االاسلامية بالاحساءء 34 Implications of Using the Flexibility to change data structures: Database structure may evolve as new requirements are defined. Availability of current information: Extremely important for on-line transaction systems such as shopping, airline, hotel, car reservations. Economies of scale: Wasteful overlap of resources and personnel can be avoided by consolidating data and applications across departments. قسم علومم االحاسب وواالمعلوماتت - كلية االشريعة وواالدررااساتت االاسلامية بالاحساءء 35 When not to use a DBMS High costs of using a DBMS: High initial investment (e.g., additional hardware). The cost of maintain the database*. When a DBMS may be unnecessary: If the database and applications are simple, well defined, and not expected to change. When a DBMS may be infeasible: In embedded systems where a general purpose DBMS may not fit in available storage When no DBMS may suffice: If there are stringent real-time requirements, high complexity, or special operations that are not supported by the DBMS. قسم علومم االحاسب وواالمعلوماتت - كلية االشريعة وواالدررااساتت االاسلامية بالاحساءء 36