Download presentation
Presentation is loading. Please wait.
Published byMyles Paul Modified over 9 years ago
3
Chapter 1 Database Access from Client Applications
4
Query by Example (QBE) n No official standard n First pass at SQL n Interactive querying or updating n Usability hierarchy n objects n functions/expressions n macros n VBA n API
5
Building Queries using QBE n Visual image of the table is used for writing queries. n Result is a dynaset n not a base table n dynamic or virtual set n may or may not be updateable n Joins (relationships) based on relationship view or created in query
6
Joins n Inner (normal) join n instructors and sections they teach n Outer join n all classes and scheduled sections n Self join n students and their advisors
7
Nested Queries n Use first query to compute lists or statistics necessary for second query n which students have any status with MIS 320? n which students have no status with MIS 320? n which sections have two or more students (with any status)?
8
Access 97 Query Types n Select n SQL n Total: group by, aggregate functions n Action: create, delete, update, append n Crosstab n Top(n)
9
Client Applications n Code generators n Switchboard: main menu form tied to special table n or, make your own n removing extraneous items
10
Reports n Banded report design n report header n page header n group header [repeatable] n detail n group footer n page footer n report footer
11
Access as a Front End n Access as the file server, uses built-in JET engine n ODBC with JET, translates queries from Access to server SQL n SQL pass-through, query must be written for server SQL n ODBCdirect, an extension to JET
12
Embedded SQL n SQL commands in 3GL programs n more flexible, accessible interface n improve performance n improve database security n Host program precompiler Source code and expanded SQL compiler Object code linker/editor Executable code
13
Visual Basic for Applications (VBA) n Benefits n complex functionality n error handling n faster execution n maintenance n OLE automation n more programmatic control n easier to read n Event-driven n event occurs n event detected n response generated
14
Chapter 2 Distributed Databases
15
Distributed Database n “A single logical database that is spread physically across computers in multiple locations that are connected by a data communications network.” n conditions that encourage use of distributed databases: n distribution and autonomy of business units n data sharing n data communications costs and reliability
16
Distributed Database Environments n Homogeneous n autonomous n non-autonomous n Heterogeneous n systems n full functionality n partial multi-database n gateways
17
Homogeneous Distributed Database Environment n Data distributed across all nodes n Same DBMS at each location n All data managed by the distributed DBMS n One global schema
18
DDBMS Objectives n Location transparency n Local autonomy n Synchronous or asynchronous n Advantages: n increased reliability n local control n modular growth n lower communications costs n faster response
19
Options for Distributing a Database n Data replication n Horizontal partitioning n Vertical partitioning n Combinations of the above
20
Data Replication n Advantages n reliability n fast response n less complicated integrity routines n node decoupling n reduced network traffic at prime time n Disadvantages n storage requirements n complexity and cost of updating
21
More on Data Replication n Schemes n snapshot replication n near real-time replication n pull replication n Replication favored when n process requests are read-only n data are relatively static
22
Partitioning (H or V) n Advantages n efficiency n local optimization n security n ease of querying n Disadvantages n inconsistent access speeds n backup vulnerability
23
Comparison of Strategies
24
Distributed DBMS n Functions n distributed data dictionary n retrieval and processing locations n translate from one DBMS to another n data management functions such as security n consistency across locations
25
DDBMS Architecture n Each site: n local DBMS n local database n distributed DBMS n distributed data repository n communications controller
26
DDBMS Objectives n Location transparency n as if all data located at a single node n Replication transparency n Failure transparency n detect … reconfigure … recover n transaction manager maintains log and concurrency control scheme n two-phase commit protocol n Concurrency transparency n timestamping
Similar presentations
© 2025 SlidePlayer.com. Inc.
All rights reserved.