Tài liệu hạn chế xem trước, để xem đầy đủ mời bạn chọn Tải xuống
1
/ 14 trang
THÔNG TIN TÀI LIỆU
Thông tin cơ bản
Định dạng
Số trang
14
Dung lượng
240,33 KB
Nội dung
Chapter 9—Database Management Systems TRUE/FALSE The database approach to data management is sometimes called the flat file approach ANS: F The Database Management System provides a controlled environment for accessing the database ANS: T To the user, data processing procedures for routine transactions, such as entering sales orders, appear to be identical in the database environment and in the traditional environment ANS: T An important feature associated with the traditional approach to data management is the ability to produce ad hoc reports ANS: F The Data Definition Language is used to insert special database commands into application programs ANS: F There is more than one conceptual view of the database ANS: F In the database method of data management, access authority is maintained by systems programming ANS: F The physical database is an abstract representation of the database ANS: F A customer name and an unpaid balance is an example of a one-to-many relationship ANS: F 10 In the relational model, a data element is called a relation ANS: F 11 Data normalization groups data attributes into tables in accordance with specific design objectives ANS: T 12 Under the database approach, data is viewed as proprietary or “owned” by users ANS: F 13 The data dictionary describes all of the data elements in the database ANS: T 14 A join builds a new table by creating links ANS: F 15 The deletion anomaly is the least important of the problems affecting unnormalized databases ANS: F 16 A deadlock is a phenomenon that prevents the processing of transactions ANS: T 17 Timestamping is a control that is used to ensure database partitioning ANS: F 18 A lockout is a software control that prevents multiple users from simultaneous access to data ANS: T 19 Logical database design is the foundation of the conceptual design ANS: F 20 An entity is any physical thing about which the organization wishes to capture data ANS: F 21 An ER diagram is a graphical representation of a data model ANS: T 22 The term occurrence is used to describe the number of attributes or fields pertaining to a specific entity ANS: F 23 Cardinality describes the number of possible occurrences in one table that are associated with a single occurrence in a related table ANS: T 24 A table in third normal form is free of partial dependencies, multiple dependencies, and transitive dependencies ANS: F 25 Improperly normalized databases are associated with three types of anomalies: the update anomaly, the insertion anomaly, and the deletion anomaly ANS: T MULTIPLE CHOICE All of the following are basic data management tasks except a data deletion b data storage c data attribution d data retrieval ANS: C The task of searching the database to locate a stored record for processing is called a data deletion b data storage c data attribution d data retrieval ANS: D Which of the following is not a problem usually associated with the flat-file approach to data management? a data redundancy b restricting access to data to the primary user c data storage d currency of information ANS: B Which characteristic is associated with the database approach to data management? a data sharing b multiple storage procedures c data redundancy d excessive storage costs ANS: A Which characteristic is not associated with the database approach to data management? a the ability to process data without the help of a programmer b the ability to control access to the data c constant production of backups d the inability to determine what data is available ANS: D The textbook refers to four interrelated components of the database concept Which of the following is not one of the components? a the Database Management System b the Database Administrator c the physical database d the conceptual database ANS: D Which of the following is not a responsibility of the Database Management System? a provide an interface between the users and the physical database b provide security against a natural disaster c ensure that the internal schema and external schema are consistent d authorize access to portions of the database ANS: C A description of the physical arrangement of records in the database is a the internal view b the conceptual view c the subschema d the external view ANS: A Which of the following may provide many distinct views of the database? a the schema b the internal view c the user view d the conceptual view ANS: C 10 Users access the database a by direct query b by developing operating software c by constantly interacting with systems programmers d all of the above ANS: A 11 The Data Definition Language a identifies, for the Database Management System, the names and relationships of all data elements, records, and files that comprise the database b inserts database commands into application programs to enable standard programs to interact with and manipulate the database c permits users to process data in the database without the need for conventional programs d describes every data element in the database ANS: A 12 The Data Manipulation Language a defines the database to the Database Management System b transfers data to the buffer area for manipulation c enables application programs to interact with and manipulate the database d describes every data element in the database ANS: C 13 Which statement is not correct? A query language like SQL a is written in a fourth-generation language b requires user familiarity with COBOL c allows users to retrieve and modify data d reduces reliance on programmers ANS: B 14 Which duty is not the responsibility of the Database Administrator? a to develop and maintain the Data Dictionary b to implement security controls c to design application programs d to design the subschema ANS: C 15 In a hierarchical model a links between related records are implicit b the way to access data is by following a predefined data path c an owner (parent) record may own just one member (child) record d a member (child) record may have more than one owner (parent) ANS: B 16 Which term is not associated with the relational database model? a tuple b attribute c collision d relation ANS: C 17 In the relational database model a relationships are explicit b the user perceives that files are linked using pointers c data is represented on two-dimensional tables d data is represented as a tree structure ANS: C 18 In the relational database model all of the following are true except a data is presented to users as tables b data can be extracted from specified rows from specified tables c a new table can be built by joining two tables d only one-to-many relationships can be supported ANS: D 19 In a relational database a the user’s view of the physical database is the same as the physical database b users perceive that they are manipulating a single table c a virtual table exists in the form of rows and columns of a table stored on the disk d a programming language (COBOL) is used to create a user’s view of the database ANS: B 20 The update anomaly in unnormalized databases a occurs because of data redundancy b complicates adding records to the database c may result in the loss of important data d often results in excessive record insertions ANS: A 21 The most serious problem with unnormalized databases is the a update anomaly b insertion anomaly c deletion anomaly d none of the above ANS: C 22 The deletion anomaly in unnormalized databases a is easily detected by users b may result in the loss of important data c complicates adding records to the database d requires the user to perform excessive updates ANS: B 23 Which statement is correct? a in a normalized database, data about vendors occur in several locations b the accountant is responsible for database normalization c in a normalized database, deletion of a key record could result in the destruction of the audit trail d connections between M:M tables is provided by a link table ANS: D 24 Which of the following is not a common form of conceptual database model? a hierarchical b network c sequential d relational ANS: C 25 Which of the following is a relational algebra function? a restrict b project c join d all are relational algebra functions ANS: D 26 Which statement is false? a The DBMS is special software that is programmed to know which data elements each user is authorized to access b User programs send requests for data to the DBMS c During processing, the DBMS periodically makes backup copies of the physical database d The DBMS does not control access to the database ANS: D 27 All of the following are elements of the DBMS which facilitate user access to the database except a query language b data access language c data manipulation language d data definition language ANS: B 28 Which of the following is a level of the database that is defined by the data definition language? a user view b schema c internal view d all are levels or views of the database ANS: D 29 An example of a distributed database is a partitioned database b centralized database c networked database d all are examples of distributed databases ANS: A 30 Data currency is preserved in a centralized database by a partitioning the database b using a lockout procedure c replicating the database d implementing concurrency controls ANS: B 31 Which procedure will prevent two end users from accessing the same data element at the same time? a data redundancy b data replication c data lockout d none of the above ANS: C 32 The advantages of a partitioned database include all of the following except a user control is enhanced b data transmission volume is increased c response time is improved d risk of destruction of entire database is reduced ANS: B 33 A replicated database is appropriate when a there is minimal data sharing among information processing units b there exists a high degree of data sharing and no primary user c there is no risk of the deadlock phenomenon d most data sharing consists of read-write transactions ANS: B 34 What control maintains complete, current, and consistent data at all information processing units? a deadlock control b replication control c concurrency control d gateway control ANS: C 35 Data concurrency a is a security issue in partitioned databases b is implemented using timestamping c may result in data lockout d occurs when a deadlock is triggered ANS: B 36 Entities are a nouns that are depicted by rectangles on an entity relationship diagram b data that describe the characteristics of properties of resources c associations among elements d sets of data needed to make a decision ANS: A 37 A user view a presents the physical arrangement of records in a database for a particular user b is the logical abstract structure of the database c specifies the relationship of data elements in the database d defines how a particular user sees the database ANS: D 38 All of the following are advantages of a partitioned database except a increased user control by having the data stored locally b deadlocks are eliminated c transaction processing response time is improved d partitioning can reduce losses in case of disaster ANS: B 39 Each of the following is a relational algebra function except a join b project c link d restrict ANS: C SHORT ANSWER Use the following words to complete the sentences Database Administrator data redundancy query language sequential structure Data Dictionary Index Sequential Access Method schema subschema _ occurs when a specific file is reproduced for each user who needs access to the file ANS: Data redundancy The conceptual view of the database is often called ANS: schema The allows users to retrieve and modify data easily ANS: query language The authorizes access to the database ANS: Database Administrator The describes every data element in the database ANS: Data Dictionary Describe a specific data element, entity, and record type in the expenditure cycle ANS: data element: vendor’s name or account balance; entity: vendor; record type: purchase requisition, purchase order What is the relationship between a database table and a user view? ANS: User views are derived database tables A single table may contribute data to several different views On the other hand, simple views may be constructed from a single table How does the database approach solve the problem of data redundancy? ANS: Data redundancy is not a problem with the database approach because individual data elements need to be stored only once yet be available to multiple users Explain how linkages between relational tables are accomplished ANS: Tables that are logically related in the data model need to be physically linked The degree of association between the tables (i.e., 1:1, 1:M, or M:M) determines how the linking occurs The key-assignment rules for linking tables are discussed below Where a true 1:1 association exists between tables, either (or both) primary keys may be embedded as foreign keys in the related table Where a 1:M (or 1:0,M) association exists, the primary key of the side is embedded in the table of the M side To represent the M:M association between tables, a link table needs to be created that has a combined (composite) key consisting of the primary keys of two related tables 10 Explain the basic results that come from the restrict, project, and join functions ANS: A restrict extracts selected rows from a table–records that satisfy prescribed conditions–to create a new table A project extracts selected attributes (columns) from a table to create a new table A join builds a new table, from two existing tables, by matching rows on a value of a common attribute 11 Explain the purpose of an ER diagram in database design ANS: The Entity Relationship (ER) diagram is the graphical representation technique used to depict a data model Each entity in a ER diagram is named in the singular noun form such as Customer rather than Customers The labeled line connecting two entities describes the nature of the association between them This association is represented with a verb such as shipped, requests, or receives The ER diagram also represents cardinality (the degree of association between two entities) Four basic forms of cardinality are possible: zero or one (0,1), one and only one (1,1), zero or many (0,M), and one or many (1,M) These are combined to represent logical associations between entities such as 1:1, 1:0,M, and M:M 12 What are two types of distributed databases? ANS: Partitioned and replicated databases 13 Describe an environment when a firm should use a partitioned database ANS: A partitioned database approach works best in organizations that require minimal data sharing among its information processing units and when a primary user of the data can be identified 14 Explain how to link tables in (1:1) association Why may this be different in a (1:0,1) association? ANS: Where a true 1:1 association exists between tables, either (or both) primary keys may be embedded as foreign keys in the related table On the other hand, when the lower cardinality value is zero (1:0,1) a more efficient table structure can be achieved by placing the one-side (1:) table’s primary key in the zero-or-one (:0,1) table as a foreign key Assume that a company has 1000 employees but only 100 of them are sales staff Assume also that each sales person is assigned a company car Therefore, every occurrence in the Employee entity is associated with either zero or one occurrence in the Company Car entity If we assigned the Company Car (:0,1) side primary to the Employee (:1) table as a foreign key then most of the foreign will have null (blank) values While this approach would work, it could cause some technical problems during table searches Correctly applying the key-assignment rule solves this problem because all Company Car records will have an employee assigned and no null values will occur APPENDIX QUESTION 15 Why are the hierarchical and network models called navigational databases? ANS: These are called navigational models because traversing or searching them requires following a predefined path which is established through explicit linkages between related records ESSAY Give three examples that illustrate how cardinality reflects an organization’s underlying business rules ANS: 1) When an organization decides to purchases the same items of inventory from different suppliers, the cardinality between the Supplier and Inventory tables is M:M 2) When a the company purchases all items of a certain type from only one supplier, the cardinality between Supplier and Inventory tables is 1:M respectively 3) A policy that a separate receiving report is prepared for the receipt of goods specified on a single purchase order will result in a 1:1 cardinality between the receiving report and purchase order tables If, however, multiple purchase orders are combined on a single receiving report then the cardinality between these tables will be 1: M respectively Explain the three types of anomalies associated with database tables that have not been normalized ANS: The update anomaly is the result of data redundancy If a data element is stored in more than one place, it must be updated in all places If this does not happen, the data are inconsistent The insertion anomaly occurs when too much data is stored together–when vendor information is only stored with specific inventory items Until items are purchased from a given vendor, the vendor cannot be added to the database The deletion anomaly is the opposite of the insertion anomaly–if a vendor supplies only one item, and the firm discontinues that item, all information on the vendor is lost when vendor information is only stored with specific inventory items What are the four elements of the database approach? Explain the role of each ANS: Users are the individuals in the organization who access the data in the database This may happen via user programs or by direct query The database management system is a set of programs that control access to the database and that manage the data resource through program development, backup and recovery functions, usage reporting, and access authorization The database administrator is a function (which may involve part of one individual’s duties or an entire department) which manages the database resources through database planning, design, implementation, operation and maintenance, and growth and change The physical database is the only physical form that the database has It is comprised of magnetic spots on magnetic media Explain the three views of a database ANS: The unique internal view of the database is the physical arrangement of records which describes the structure of data records, the linkages between files, and the physical arrangement and sequence of records in the file The unique conceptual view (or schema) represents the database logically and abstractly The many user views (or subschema) define the portion of a database that an individual user is authorized to access Explain a database lockout and the deadlock phenomenon Contrast that to concurrency control and the timestamping technique Describe the importance of these items in relation to database integrity ANS: In a centralized database, a lockout is used to ensure data currency A lockout prevents simultaneous access to individual data elements by different information processing units (IPU) When one IPU requests access to a data element, a lock is put on the file, record, or element No other IPU can access the file, record, or element until the lock is released In a partitioned database, lockouts are also used to ensure data currency It is possible, however, for multiple sites to place locks on records that results in a deadlock condition which prevents transactions from processing All transactions are in a “wait” state until the locks are removed A deadlock cannot be resolved without outside intervention from the user’s application, the DBMS, or the operating system In a replicated database, a large volume of data flows between sites, and temporary inconsistencies in the database may occur Concurrency control ensures that transactions executed at each IPU are accurately reflected in the databases of all other sites A popular method for concurrency control is to timestamp transactions Transactions that may be in conflict are assigned a system-wide timestamp Then, the identified transactions are processed in timestamp order Both database lockouts and concurrency controls are designed to ensure that the transactions are completely processed and that all transactions are accurately reflected in the firm’s databases Failure to implement these controls can result in transactions being lost, being partially processed, or with inconsistent databases What are the key control implications of the absence of database normalization? ANS: When considering the quality of the data in a database, accountants should be aware of the outcomes of typical anomalies The update anomaly can yield conflicting data in the database The insertion anomaly can result in unrecorded transactions The deletion anomaly can cause loss of accounting information and destruction of the audit trail In a distributed data processing system, a database can be centralized or distributed What are the options? Explain ANS: In a distributed data processing system, a database can be centralized or distributed When the database is centralized, the entire database is stored at a central site which processes requests from users at remote locations Certain concerns arise when data processing is distributed Questions arise with regard to data currency when multiple users have access to the database Database lockout prevents more than one user from making changes at the same time Distributed databases can be partitioned with parts stored at different sites, or replicated, with the entire database stored in multiple locations When the database is partitioned, users have more control over data stored at local sites, transaction processing time is improved, and the potential of data loss is reduced When the database is replicated, the entire database is stored at multiple locations This works well when the primary use of the database is for querying When transactions are processed at many sites, problems of database concurrency arise What are the characteristics of a properly designed relational database table? ANS: The characteristics of a properly designed relational database table are: a All occurrences at the intersection of a row and column are a single value b The attribute values in any column must all be of the same class c Each column in a given table must be uniquely named d Each row in the table must be unique in at least one attribute which is considered the primary key Ownership of data in traditional legacy systems often leads to data redundancy This in turn leads to several data management problems What are they? How does the database approach solve them? ANS: Data redundancy causes significant data management problems in three areas: data storage, data updating, and currency of information Data storage is a problem because if multiple users need the data, it must be collected and stored multiple times at multiple costs When multiple users hold the same information, changes must be updated in all locations or data inconsistency results Failure to update all occurrence of a data item can affect the currency of the information With a database system, these problems are solved There is no data redundancy since a data item is stored only once Hence changes require only a single update, thus leading to current value 10 What services are provided by a database management system? ANS: Database management systems typically provide the following services: a program development which permits both programmers and end users to create applications to access the database; b backup and recovery is built in therefore reducing likelihood of data loss; c database usage reporting captures statistics on what data is being used, by whom, when; and especially d database access is provided to authorized users 11 Discuss the key factors to consider in determining how to partition a corporate database ANS: The partitioned approach works best for organizations that require minimal data sharing among users at remote sites To the extent that remote users share common data, the problems associated with the centralized approach will apply The primary user must now manage requests for data from other sites Selecting the optimum host location for the partitions to minimize data access problems requires an in-depth analysis of end-user data needs 12 Distinguish between a database lockout and a deadlock ANS: To achieve data currency, simultaneous access to individual data elements or records by multiple users needs to be prevented The solution to this problem is a database lockout, which is a software control that prevents multiple simultaneous accesses to data A deadlock occurs when multiple users seeking access to the same set of records lockout each other As a result, the transactions of all users assume a “wait” state until the locks are removed A deadlock is a permanent condition that must be resolved by special software that analyzes each deadlock condition to determine the best solution 13 Replicated databases create considerable data redundancy, which is in conflict with the database concept Explain the justification of this approach ANS: The primary justification for a replicated database is to support read-only queries in situations involving a high degree of data sharing, but no primary user exists With data replicated at every site, data access for query purposes is ensured, and lockouts and delays due to network traffic are minimized A potential problem arises, however, when replicated databases need to be updated by transactions Since each site processes only local transactions, the common data attributes that are replicated at each site will be updated by different transactions and thus, at any point in time, will have uniquely different values System designers need to employ currency control techniques to ensure that transactions processed at different locations are accurately reflected in all the databases copies APPENDIX QUESTION 14 Contrast the navigational databases with relational databases What is the primary advantage of the relational model? ANS: The most apparent difference between the relational model and navigational models is the way that data associations are represented to the user In navigational models, data are represented in tree structures or network structures The navigational database models have explicit links, called pointers, between records Data are accessed using defined data paths The relational model portrays data in the form of two-dimensional tables Users not perceive any pointers linking the tables At the conceptual level (logical view) and the external level (user’s view), data are represented only as tables Relations between tables are formed by an attribute (data element) that is common to the tables This attribute is a primary key in one table and a foreign key in the other The relational model is more flexible than a navigational model Users can obtain data from the database by using the primary key and a database query language Typically users not require assistance from programmers to obtain answers to ad hoc queries ... views of the database? a the schema b the internal view c the user view d the conceptual view ANS: C 10 Users access the database a by direct query b by developing operating software c by constantly... deletion of a key record could result in the destruction of the audit trail d connections between M:M tables is provided by a link table ANS: D 24 Which of the following is not a common form of conceptual... comprised of magnetic spots on magnetic media Explain the three views of a database ANS: The unique internal view of the database is the physical arrangement of records which describes the structure of