The Entity-Relationship Model for Multilevel Security

The Entity-Relationship Model for Multilevel Security Günther PERNUL, Werner WINIWARTER, A Min TJOAInstitute of Applied Computer Science and Information SystemsUniversity of Vienna, AustriaAbstract. A design environment for security critical database applications thatshould be implemented by using multilevel technology is proposed. For thispurpose, the Entity-Relationship model is extended to capture securitysemantics. Important security semantics are defined and a language to expressthem in an ER model by means of security constraints is developed. The maincontribution consists of the development and implementation of a rule-basedsystem with which security semantics specified may be checked for conflictingconstraints. The check involves application independent as well as applicationdependent integrity constraints and leads to a non conflicting conceptualrepresentation of the security semantics of a multilevel secure databaseapplication.1 IntroductionDesigning a database is a complex and time consuming task, even more in the case attention must be given to the security of the information being considered for representation in the database. In order to simplify the design activity, it is necessary to look at the database application at an abstract level by using a conceptual data model, for example, the Entity-Relationship (ER) Model [1].A conceptual data model must be powerful enough to capture all application dependent knowledge. For applying such a model successfully for the design of a security critical application, the model must in addition to represent the data semantics represent the security properties of data (i. e. the security semantics of the application) as well. The ER model provides a graphical language to describe the information items of the application by means of semantic modeling constructs. Unfortunately, it does only offer restricted possibilities to represent constraints that are imposed on those information items by the application, such as for example security constraints. The goal of this paper is to extend the notion of the standard ER model to also capture security semantics, to provide a language in which application dependent security requirements may be expressed on the concepts of the ER model, and to provide a technique to check constraints resulted from the security requirements for overall consistency. The model proposed includes two levels of representation for security semantics. At the user level we introduce a graphical representation and a constraint language, and at an internal level a knowledge baseto check for conflicting constraints. The constraint language and the knowledge base to check conflicting constraints has already been implemented by using the deductive DBMS LDL, the implementation of the user interface (graphical browser) including the proposed graphical extensions to ER is under development.The outline of the paper is as follows: Section 2 contains relevant related work. In section 3 the security semantics are defined, expressed in the constraint language, and explained by means of an example. Section 4 deals with conflict management in order to achieve a non conflicting representation of a MLS database application. Section 5 concludes the paper.2 Background and Related WorkFor applications in which the secrecy and confidentiality of the information is of major concern DBMSs supporting Mandatory Access Controls (MAC) may be chosen. Mandatory Security requires that data and users are assigned to certain security classifications (security levels, like top-secret, secret, classified, unclassified, or like company-confidential, confidential, private, public, ...). A level represents the sensitivity of the labeled information (classification) or the trustworthiness of a user (clearance) not to disclose information to other users not so trusted. Classifying data is done by means of rules and one of the major questions involved is how the data of a database should be classified without specifying conflicting rules.Mandatory security is often defined in terms of the Bell-LaPadula (BLP) [2] security paradigm which distinguishes between read access and write access by using the two following rules: (1) User u is allowed to read data d if clear(u) ≥class(d) and (2) u is allowed to write data if clear(u) ≤class(d). Because of this two rules, information flow controls are implemented restricting users with high clearances to write data in a lower classified storage area and thereby disclosing sensitive information. Mandatory security leads to multilevel secure (MLS) databases because the content of the database may appear different for users with different clearances. For more information and for a formal treatment of the MLS relational data model consult [3] or [4]. Today, there are several commercially MLS database management systems available, for example Informix, Ingres, Oracle, Rdb, Sybase, and others offer in addition to their general purpose system a multilevel version. However, the first and most prestigious effort towards the design and implementation of a MLS DBMS has come from the SeaView project (e.g. [5], [6]).In this paper we focus on database applications that should be implemented in systems supporting a MLS data model. In this context, the major problems involved are to identify the security semantics (requirements) of the application, to specify the security sementics by means of constraints and rules in a conceptual data model, to check the constraints for completeness and to resolve conflicts between security semantics. The conceptual model developed in the proposed approach may be finally transferred into the MLS data model that is supported by a target DBMS in use.Compared to the huge amount of work published in semantic modeling and conceptual design of databases not much work has been done investigating securitysemantics of MLS database applications. Only recently several research efforts have started to provide tools and assistance to aid a designer in creating a MLS application. The first attempt to use a conceptual model to represent security semantics is given in [7] and [8]. The author develops the semantic model for security (SDMS) based on a conceptual database model and extends the constraint language ALICE (proposed in [9]) to include constructs to describe security constraints. In contrast to the proposed approach their model has not been completely formalized and does not offer sophisticated techniques for the detection of conflicting constraints and if existing, techniques for their resolution. A more recent approach has been made in [10] and [11]. The authors have developed the SPEAR model which is a high-level data model and similar to the ER approach. This model consists of an informal description of the application domain and of a formal mathematical specification using the Z-notation [12]. The model seems to be powerful, however does not offer a graphical notation and only limited support to detect conflicting constraints. Two further related projects are known. Both projects consider, in addition to modeling the static of the application, to include the behavior of the system within the datbase design process. In [13] the ER model has been extended to capure limited dynamics by including the operations 'create', 'find' and 'link' into the conceptual database representation while in [14] ER has been used to model the static part of a MLS application and data flow diagramming to model the behavior of the system. Both approaches do not offer any consistency checks of the security constraints specified.The proposal in this paper extends previous work on security semantics by •carefully defining the major security semantics that need to be represented during the design of a database,•by developing a constraint language for expressing corresponding rules in a conceptual model (ER model) of the appliciation, and•by developing and implementing a rule-based system with which security semantics specified may be tested for conflicts. Conflicting constraints are notified to the designer and may be resolved. The rule-based system is implemented by using the deductive DBMS LDL.3 Concepts of Security SemanticsIn the following we give a taxonomy of security semantics which consists of the most common requirements on multilevel security. Each concept is formally defined, expressed in the security constraints language (SCL), graphically included in the notion of the ER model, and explained by means of an example. We will start with defining the basic concepts.A security object O is a semantic concept of reality that is described by certain properties. Using extended ER terminology, O might be an entity type, a specialization type, a generic object type, or a relationship type. In a security terminology, O is the target of protection and might be denoted by O(A1,...,A n). A i is a characteristic property and defined over a domain D i. Each security object Omust have an identifying property K(K⊆{A1,...,A n}) which is either a single characteristic property or a set of properties that combined together form an identifier and make instances (occurrences) o∈O(o={a1, ..., a n}, a i∈D i) distinguishable from others.Moving to a multilevel world each property of a security object must be assigned to at least one security level. A security level is an entry in a hierarchical list of levels SL. A multilevel security object O m(A1,C1, A2,C2, ..., A n,C n) is a security object where each characteristic property A i is assigned to a security classification C i. The valid domain of C i is specified by an interval consisting of possible security classifications between the lowest classification (L i) and the highest classification (H i) possible for a value of characteristic property A i(L i, H i∈SL). The set of instances of a multilevel security object is a set of distinct tuples of the form (a1,c1, a2,c2, ..., a n,c n,) where each a i∈D i, c i∈[L i,H i].The process of assigning data items to security classifications is called classifying and results into the transformation of a security object O into a corresponding multilevel security object O m (O⇒O m). The transformation is performed by means of security constraints specified in a constraints language.In the following we give a taxonomy of the most relevant security semantics that should be expressed in a conceptual data model. Some of the constraints have been discussed before (e.g. in [7], [15]), however, to the best of our knowledge the following is the first careful formalisation of the constraints. It is distinguished between two kinds of constraints: Constraints that classify characteristic properties of security objects (simple, content-based, complex, and level-based constraints) and constraints that classify retrieval results (association-based, inference, and aggregation constraints).The example design scenario that will be used represents part of a hospital information system containing historical information. Of interest are the security objects:•patient (ssn, pname, karnofski, incompatibility)•treatment (ssn, icd, duration, status, course)•disease (icd, dname, medication)3.1 Simple ConstraintsThese constraints classify certain characteristic properties of security objects. By assigning a security classification to the identifying property even the information about the existence of the security object can be classified.• Definition: Let X be a set of characteristic properties of security object O i.e. X⊆{A1,..,A n}. A simple security constraint SiC is a classification of the form SiC(O(X))=C, C∈SL and results into a multilevel object O m(A1,C1,A2,C2, ..., A n,C n) whereby C i=C for all A i∈X, C i left unchanged for the remaining A i∉X.• SCL predicate:sic(O, X, C)O ... security object, X ... set of classified characteristic properties,C ... security level•Example:The status of a medical treatment should be regarded as private information. ⇒sic(treatment, {status}, private)3.2 Content-Based ConstraintsThey classify characteristic properties of instances of security objects based on the evaluation of a predicate on a specific characteristic property of the same instance.• Definition: Let A i be a characteristic property of security object O with domain D i, let P be a predicate defined on A i and let X⊆{A1,...,A n}. A content-based constraint CbC is a classification of the form CbC(O(X),P:A iθa)=C or CbC(O(X),P:A iθA j)=C (θ∈{=,>,<,≥,≤,≠}, a i∈D i, D i⊆D j,i≠j, C∈SL).For any instance of security object (A1,...,A n) for which a predicate evaluates into true the transformation into (a1,c1, a2,c2, ..., a n,c n) is performed. Classifications are assigned in a way that c i=C in the case A i∈X, c i left unchanged otherwise.• SCL predicate:cbc(O, X, A, Theta, V, C)A ... evaluated characteristic property A i, Theta ... comparison operator θV ... comparison value a or characteristic property A j• Example: Medical treatments have to be classified as confidential, if the duration exceeds 8 months. ⇒cbc(treatment, {ssn, icd}, duration, '>', 8, confidential)3.3 Complex ConstraintsTwo different security objects participating in a dependency relationship are involved in the definition of a complex constraint. As consistent extension of the content-based constraint the predicate is evaluated on a specific characteristic property of the independent security object leading to a classification of properties of the associated dependent object.•Definition: Let O,O' be two security objects and the existence of an instance o of O is depending on the existence of a corresponding instance o'of O'whereby the k values of the identifying property K' for o' are identical to k values of characteristic properties of o (foreign key).Let P(O')be a valid predicate (as stated above for content-based constraints) defined on O' and let X⊆{A1,...,A n} be an attribute set of O. A complex security constraint CoC is a classification of the form CoC(O(X),P(O'))=C. For any instance o of security object O for which the predicate evaluates into true in the related object o' of O', the transformation into (a1,c1, ..., a n,c n) is performed. Classifications are assigned in that c i=C in the case A i∈X, c i left unchanged otherwise.• SCL predicate:coc(OD, X, O, A, Theta, V, C)OD ... dependent security object O, O ... independent security object O',• Example: The data about treatments of patients suffering from carcinoma has to be processed as most sensitive information.⇒coc(treatment, {ssn}, disease, dname, '=', carcinoma, secret)3.4 Level-Based ConstraintsIf data items are classified on the basis of the classification of some other characteristic property of the same security object, this dependency is expressed by means of a level-based constraint. This signifies that for all instances of the security object the concerned characteristic properties are enforced to be always labeled by the same security level.• Definition: Let level(A i) be a function that returns the classification c i of the value of a characteristic property A i for the instance o m(a1,c1,a2,c2, ..., a n,c n) of a multilevel security object O m. Let X be a set of characteristic properties of the same security object O such that X⊆{A1,...,A n}. A level-based security constraint LbC is a classification of the form LbC(O(X))=level(A i)and results into the classification of the values of all A j∈X (j≠i) with the security levels level(A j)=c i.• SCL predicate:lbc(O, X, A)• Example: The information about the course of a disease in response to the medical treatment has to be protected to the same extent as the status of the patient.⇒lbc(treatment, {course}, status)Fig. 1. Example of constraints on characteristic propertiesFigure 1 contains the summarised graphical representation of the constraints classifying characteristic properties as discussed in the examples given above.3.5 Association-Based ConstraintsThey restrict from combining the values of certain characteristic properties with the identifying property of the security object in the retrieval result. This permits theaccess to collective data but prohibits the user from identifying the properties of the individual instances of the security object.• Definition: Let O(A1,...,A n) be a security object with identifying property K. Let Y ⊆{A1,...,A n}, K∩Y={} be a set of characteristic properties of O. An association-based security constraint AbC(O(K,Y))=C results into the assignment of security level C to the retrieval result of each query that takes Y together with identifying property K.• SCL predicate:abc(O, Y, C)Y ... set of sensitive characteristic properties Y⊆{A1,...A n}, K∩Y={},• Example: The karnofski indices (indicating the state of health of a patient) shall be freely available as anonymous statistical coefficient. However, for an individual patient this private information is sensitized by classifying it as private. ⇒abc(patient, {karnofski}, private)3.6 Inference ConstraintsThese constraints prevent from drawing inferences from seemingly independent data items to higher classified information. Inferences can occur because of hidden relations that are not explicitely represented in the conceptual data model of the MLS database, also involving knowledge beyond the scope of the database system.• Definition: Let PO be the set of multilevel objects involved in a potential logical inference. Let O, O' be two particular objects from PO with corresponding multilevel representations O(A1,C1, ..., A n,C n) and O'(A'1,C'1, ..., A'm,C'm). Let X⊆{A1,...,A n} and Y⊆{A'1,...,A'm}. A logical inference security constraint IfC is a statement IfC(O(X),O'(Y))=C and results into the assignment of security level C to the retrieval result of each query that takes Y together with the properties in X.• SCL predicate: if c(O1, X1, O2, X2, C)O1 ... security object O,X1 ... set of sensitive characteristic properties X of O,O2 ... independent security object O',X2 ... set of sensitive characteristic properties Y of O',• Example: The characteristic property incompatibility indicates allergic reactions of a patient against certain drugs that were diagnosed during past medical treatments. Therefore, one could infer recent diseases of a patient from the detected incompatible medicaments combined with the information which medication is applied for a specific disease. To close this forbidden inference channel an appropriate inference constraint is stated that assigns it with a security level of secret. ⇒if c(patient, {pname, incompatibility}, disease, {dname, medication},secret)3.7 Aggregation ConstraintsIn some cases the retrieval of several instances of a security object is regarded as more sensitive than a result consisting only of a single instance. This phenomenon is known as the aggregation problem. It occurs in cases where the query is narrowed on a sensitive characteristic property and information about that property can be concluded from the total retrieval result.•Definition: Let count(O)be a function that returns the number of instances involved in a particular query and belonging to security object O(A1,...,A n). Let A i be a sensitive characteristic property of O that is used for narrowing the query by defining a selection criterion on A i.An aggregation security constraint AgC is a statement of the form AgC(O(A i,count(O)>n))=C(n∈Ν) and results into the classification of C for the retrieval result in the case count(O)>n, i.e. the number of obtained instances of O exceeds the threshold value n.• SCL predicate:agc(O, A, N, C)A ... sensitive characteristic property A i, N ... threshold value n •Example:The report of an individual medical treatment for a specific patient is regarded as less sensitive than the complete medical history obtained from a retrieval of all medical treatments of the patient. Therefore, an aggregation-based constraint is formulated that declares a threshold value of 5 treatments. If this limit is exceeded, a security classification of level confidential is performed. ⇒agc(treatment, ssn, 5, confidential)Figure 2 contains the summarised graphical representation of the constraints classifying retrieval results of the examples given above.F ig. 2. Example of constraints on retrieval results4 Conflict ManagementFor complex and security critical database applications it might be necessary that a large set of security constraints need to be expressed at the conceptual database level. In the following we will discuss the methods used for the detection of conflicting constraints specified as well as the techniques used for the conflict resolution. The conflict management represents the internal layer of the proposed approach and isresponsible to enforce two different kinds of integrity constraints in the security semantics specified: application independent and application dependent integrity constraints. Conflict management is performed by our prototype implementation in LDL. For a more detailed study of conflict management we refer to [16].4.1 Integrity of Security SemanticsApplication independent integrity constraints are rules that must be valid in each MLS database. By expressing the security constraints introduced on the conceptual representation of the database application, integrity constraints might be violated. In the proposed system, those conflicts are detected automatically by the implemented rule system, the conflicts are resolved and finally notified to the designer. However, in the case a conflict involves an application independent integrity constraint, the designer is not given a possibility to override the changes performed by the tool. Some of the following integrity properties have first been proposed within the SeaView project [5] and have been carefully defined in the Jajodia-Sandhu model [3]. For conflict management we consider:[I1]Multilevel integrity property: Each property must have a security label. This is satisfied because during initial classifying each characteristic property is classified with the default security level.[I2]Entity integrity property: A multilevel security object O m with identifying property K satisfies entity integrity property if for all occurrences o∈O m1. A i∈K⇒ val(A i)≠null (with val(A i) the value of property A i in o)2. A i,A j∈K⇒ val(C i) = val(C j) (with val(C) classification of property A in o)3. A i∉K⇒ val(C K)≤val(C i). (with val(C K) classification of the key-value in o) Entity integrity states that an indentifying property may not be null, must be uniformly classified and its classification must be dominated by all other classifications of the other attributes. This is necessary because by having only access to part of the key for lower cleared users it would not be possible to uniquely identify objects. Please note that this may contradict to certain applications, for example, in applications where access to key-properties should be denied while access to some other non-identifying properties should be possible (e.g. for statistical queries).[I3]Foreign key property: Let K be the identifying property in multilevel security object O m and and let it be a foreign key K' in multilevel security object O m'. The foreign key property is valid, if val(C K) ≤val(C K'). The foreign key property guarantees that no dangling references between depending objects will occur for users cleared to access lower classified data only.[I4]Near-key property: Near-key property is important in the case an association based constraint is specified. In this case the level C assigned by the constraint abc(O, X, C) is automatically propagated to each corresponding association including a near-key (or candidate key) instead of the identifying property of O.[I5]Level-based property: In order to avoid transitive dependencies (which may result into propagation cycles) between level-based constraints specified, for any two level-based constraints on the same security object lbc(O, X, A) and lbc(O, X', A') A∉X'∧A'∉X must hold. Because of the entity integrity property a level-based constraint may not be defined on the key.[I6]Multiple-Classification: Each property value may only have a single classification. In the case different security constraints assign more than one level to a particular property value we refer to it as multiple-classification. Such a conflict is notified to the designer which may decide whether to apply the default resolution strategy or not.4.2 Conflict Resolution Stategies and the Example DesignClassifying is done by stepwise insertion of security constraints into the rule-base. Declaring a new constraint is an interactive process between the designer and the tool. The six integrity constraints given above must be validated for any new security constraint specified. If conflicts are detected the resolution strategy applied depends on the kind of conflict. For conflicts due to application independent constraints the integrity is preserved by propagating the required classifications to the characteristic properties involved. Application dependent constraints leading to multiple-classification of characteristic properties are notified to the designer who may decide about a proper classification. As default strategy the design tool suggests the maximum of the conflicting security levels to guarantee the highest degree of security possible. However, accepting the default strategy may lead to overclassification of the database.Let us now explain the conflict resolution strategies by applying them to the example and the security constraints developed in the preceding chapters, summarized once more:1.sic(treatment, {status}, private)2.cbc(treatment, {ssn, icd}, duration, '>', 8, confidential)3.coc(treatment, {ssn}, disease, dname, '=', carcinoma, secret)4.lbc(treatment, {course}, status)5.abc(patient, {karnofski}, private)6.if c(patient, {pname, incompatibility}, disease, {dname,medication},secret)7.agc(treatment, pssn, 5, confidential)The process starts with the initial assignment of the default security level public to each data item. The insertion of 1) results in the assignment of security level private to property status. No conflicts arise. Constraint 2) is a cbc and results into the assignment of the range [∅..C] to properties ssn and icd. That is, in the case the predicate evaluates into true classification C is assigned, otherwise the classifications remain public (i. e. the default value denoted as ∅). In order to resatisfy the application independent property that the classification of the key must be dominated by all other classifications (entity integrity property as stated above) the assigned classifications are propagated to the other properties of relationship type treatment. The propagation results into the first conflict between application dependent constraints specified. This is because of property status (which is already classifiedas private by 1)) will be multiple-classified by propagating [∅..C]. This conflict is notified to the designer. Let us consider that the designer confirms the suggested default resolution strategy resulting in the assignment of range [P..C] to property status.The next rule 3) is a coc that assigns the ssn of patients suffering from 'carcinoma' in treatment to secret.This leads to a classification range for the property ssn of [∅..S]. Again this disagrees with the already existent range of [∅..C] for ssn. Therefore, the designer has to decide whether to accept the suggested classification range [∅..S] or not. In the case of acceptance the new classification of ssn must be propagated to icd because of entity integrity (icd constitutes the second part of the key). Now the complete key takes the new classification [∅..S] which makes the propagation of [∅..S] to all other properties of treatment necessary. This propagation again causes multiple-classification of all non-identifying properties of treatment resulting in further notations for the designer (once more confirmed). Lbc 4) assigns the classification of status to course, yielding a new range of [P..S] for course. The designer receives the notation about the conflicting ranges [P..S] and [∅..S] and chooses the default resolution strategy. The remaining security constraints 5)-7) do not deal with characteristic properties but instead classify retrieval results. Because of the near-key integrity constraint 5) is also propagated to the near-key pname in patient. The remaining constraints 6) and 7) do not cause any conflicts.5 ConclusionFor security critical database applications MLS technology may be chosen as the implementation platform. In such an environment data items need to be assigned to security classifications that properly represent the security semantics of the database application. In this paper we have carefully defined the important security semantics that need to be represented during the design of a database, have developed a constraint language for expressing them, and have suggested to extend the Entity-Relationship model to capture security semantics. We see as the main contribution of our research the development of a rule-based system holding classification rules and certain integrity constraints that must be valid among the rules specified. Whenever a database designer inserts a new classification rule, the rule-base is checked for resulting conflicts. The checks are performed against the integrity constraints and all other rules already in the rule-base. In the case a classification rule causes conflicts, a conflict resolution strategy has been developed and implemented.The research presented in this paper provides the basis to assist database designers and security engineers in getting a better understanding of the security requirements of the static part of the database application. Future research in this area may be required because the security of a database may also be violated by abusing the functional part of the system. What will be necessary to do in order to achieve a high degree of data protection is to look at the dynamic aspects of MLS database applications too.。

合集下载

《软件工程》习题汇锦

《软件工程》习题汇锦

《软件工程》习题汇锦一、单项选择题提示:在每小题列出的四个备选项中只有一个是符合题目要求的,请将其代码填写在下表中。

错选、多选或未选均无分.1. ( )If a system is being developed where the customers are not sure of what theywant, the requirements are often poorly defined。

Which of the following would be an appropriate process model for this type of development?(A)prototyping(B)waterfall(C)V-model(D)spiral2. ()The project team developing a new system is experienced in the domain.Although the new project is fairly large, it is not expected to vary much from applications that have been developed by this team in the past. Which process model would be appropriate for this type of development?(A)prototyping(B)waterfall(C)V-model(D)spiral3. ()Which of the items listed below is not one of the software engineering layers?(A)Process(B)Manufacturing(C)Methods(D)T ools4. ()Which of these are the 5 generic software engineering framework activities?(A)communication,planning,modeling,construction,deployment(B) communication, risk management, measurement,production, reviewing(C)analysis,designing,programming, debugging, maintenance(D)analysis, planning,designing,programming,testing5. ()The incremental model of software development is(A)A reasonable approach when requirements are well defined.(B)A good approach when a working core product is required quickly。

实体关系模型

实体关系模型

Although several candidate keys may exist, one of the candidate
keys is selected to be the primary key.
Database System Concepts - 5th Edition, Oct 5, 2006
customer and account may have the attribute access-date
Database System Concepts - 5th Edition, Oct 5, 2006
6.7
©Silberschatz, Korth and Sudarshan
Degree of a Relationship Set
Refers to number of entity sets that participate in a relationship
set.
Relationship sets that involve two entity sets are binary (or
degree two). Generally, most relationship sets in a database system are binary.
Relationship Sets
A relationship is an association among several entities
Example: Hayes customer entity taken from entity sets
depositor relationship set
6.10
©Silberschatz, Korth and Sudarshan

软件工程复习(英文)

软件工程复习(英文)

1.Which question no longer concerns the modern softwareengineer? (a)现如今的软件工程师不再考虑以下哪个问题?a. Why does computer hardware cost so much? 计算机硬件为什么如此昂贵b。

Why does software take a long time to finish?c。

Why does it cost so much to develop a piece of software?d. Why can’t software errors be removed from productsprior to delivery?2.Software deteriorates rather than wears out because(c)软件通常是变坏而不是磨损的原因是a。

Software suffers from exposure to hostile environmentsb。

Defects are more likely to arise after software has been used oftenc. Multiple change requests introduce errors in component interactions在组件交互中需求发生变化导致错误d. Software spare parts become harder to order3.Most software continues to be custom built because(d)大多数软件产品是定制的原因是a。

Component reuse is common in the software worldb. Reusable components are too expensive to usec. Software is easier to build without using someone else’s components.d. Off the shelf software components are not commonly available 现成的软件组件不常用4.The nature of software applications can be characterized by their information(d)软件应用的本质可以被特色化,通过他们信息的a. complexityb。

数据库系统概念(database system concepts)英文第六版 第一章

数据库系统概念(database system concepts)英文第六版  第一章
Network model Hierarchical model
Relational Model
Relational model (Chapter 2) Example of tabular data in the relational model
Columns
Rows
A Sample Relational Database
In the early days, database applications were built directly on top of
Drawbacks of using to store data
Data redundancy and inconsistency Multiple , duplication of information in different files
Concurrent access by multiple users Concurrent access needed for performance Uncontrolled concurrent accesses can lead to inconsistencies – Example: Two people reading a balance (say 100) and updating it by withdrawing money (say 50 each) at the same time
Entity Relationship Model (Chapter 7) Models an enterprise as a collection of entities and relationships Entity: a “thing” or “object” in the enterprise that is distinguishable from other objects – Described by a set of attributes Relationship: an association among several entities Represented diagrammatically by an entity-relationship diagram:

L6 Entity-Relationship Model - 1

L6 Entity-Relationship Model - 1

Software School, Fudan University
Database Design
Autumn Semester, 2009
12
Attribute Types
Simple and composite attributes “address” may be structured as a composition of subparts. Single-valued and multi-valued attributes “phone_number” may have a set of values for a specific entity. Number of values may have upper or lower bounds. Derived attributes Can be computed from other attributes (by aggregation, or by arithmetic calculations) The customer entity set can have an attribute loans_held indicating the number of loans a customer holds. The age attribute can be calculated with date_of_birth.
– Stored attribute (or base attribute)
Software School, Fudan University
Database Design
Autumn Semester, 2009
Composite Attributes
13
Software School, Fudan University

ch6 Entity-Relationship Model解读

ch6 Entity-Relationship Model解读
Most useful in describing binary relationship sets. For a binary relationship set the mapping cardinality must be one
of the following types:

华南理工大学 软件学院
6.10
Composite Attributes
6.11
华南理工大学 软件学院
Mapping Cardinality Constraints
Express the number of entities to which another entity can be
associated via a relationship set.
(customer_id, account_number) is the super key of depositor NOTE: this means a pair of entity sets can have at most one relationship in a particular relationship set.
Diamonds represent relationship sets.
Lines link attributes to entity sets and entity sets to relationship sets. Ellipses represent attributes
A relationship set is a mathematical relation among n 2
entities, each taken from entity sets

ERDraw An XML-based ER-diagram Drawing and Translation Tool

• Representing ER-diagrams in XML. As addressed by P. Chen, the ER model has a close relationship with XML and the web [2]. To support this trend, we have defined ERML, a language based on XML to convert an ER-diagram into ERML format and vice versa. In this paper, we describe the DTD of ERML, hoping that it will be used as a public XML exchange format for ER-diagrams between different ER tools.
ERDraw: An XML-based ER-diagram Drawing and Translation Tool
Shuyun Xu Wayne State University
Detroit, MI 48202 sxu@
Yu Li Micro Research Ins. Inc
The ER model was introduced as a tool for data modeling by P. Chen in 1976 [1]. Together with its different variants [3, 4], it has been used successfully in data modeling and database design in more than two decades. Based on the notion of ER modeling which was generalized to conceptual modeling afterwards, an international conference was initiated in 1979 and has been held annually [5] thereafter. Several commercial products have been developed to support drawing ER-diagrams in a graphical fashion. They include Embarcadero Tech’s ER/Studio [6], Microsoft’s Visio [7], and Dia [8] that are developed by A. Larsson, et al.

数据库原理第2章E-R模型培训讲学

– Y是支配实体dominant entity (如下例中的贷) – X是从属实体subordinate entity (如下例的付款)
loan
loan-payment
payment
如果贷款实体被删除,则其相关的付款实 体也必须删除。
• Total participation 全部参与 loan对 2020/8b/19orrow联系集
2020/8/19
Entity Sets 实体集
• 数据库可由下列内容模型化:
– 实体的集合 – 实体间的关系
• 实体:是现实世界中可区别于其他对象的“ 事件”或“物体”。
例如:指定的人、公司、事件、工厂
• 实体集:是拥有相同特性的同类型实体的集 合。
例如所有人、公司、树、节假日的集合
▪组成实体集的各实体称为实体集的外延。 2020/8/19
如果联系集R有属性a1,a2 ,…,am 与之相关联,那么属性集合 primary-key(E1)U primary-key(E2)U…U primary-key(En)U{a1,a2
▪ ,…,am}表示集合R中一个独立的联系。 对于以上两种情况,属性集合primary-
key(E1)U primary-key(E2)U…U primary-
Entity Sets customer and loan 实体集:客户和贷款
customer-id customer- customer- customername street city
loan- amount number
2020/8/19
Composite Attributes 组合属性
– 例如: 2020/8/19
Relationship Set borrower

SSD7数据库系统选择题答案

Multiple-Choice Quiz 11.An E-Commerce system consists of the following components. Which of these same components must be included in a database? (c)The data, such as information about the goods available for sale, customers, orders placed, shipping information, etc.A database must include a collection of programs that control the data, such as programs to create, maintain, and manipulate the data. These programs can be easily used to create, maintain, and manipulate data in other domains.A database must include a collection of programs that operate on the data, but are specific to the E-commerce system. These programs enable users to browse through the store-items, place orders, track shipping, etc.(a) I, II, and III(b) I and II only(c) I only(d) II only2.An E-Commerce database contains data about customers, products, orders, system response times, etc. Which of the following can be specified as integrity constraints in an E-Commerce database system? (d)No two products can have the same product ID.The DBMS response time for all Web requests should be at most 2 seconds.A customer order cannot have more than one shipping address.(a) I only(b) I, II, and III(c) I and II only(d) I and III onlyFeedback: The constraints I, II and III specify the application semantics of the data captured in the E-Commerce database. Constraint III, although it seems contrary to common sense, is not something that can be prohibited by the DBMS because the DBMS is general purpose. The response time of the DBMS cannot be enforced by the DBMS. It depends on factors such the processor speed, memory available, etc.3. An E-Commerce system consists of the following components. Which of these same components will constitute a database system? (d)The data, such as information about the goods available for sale, customers, orders placed, shipping information, etc.A collection of programs that control the data, such as programs to create, maintain, and manipulate the data constitutes a database system. These programs can be easily used to create, maintain, and manipulate data in other domains such as in a library information system.A collection of programs that operate on the data, but are specific to the E-commerce system, constitutes a database system. These programs enable users to browse through the store-items, place orders, track shipping, etc.(a) I and II only(b) II only(c) I only(d) I, II, and IIIFeedback: A database system includes the data, the DBMS, and the application-specific programs that operate on that data.5. In a database system, whose responsibility is it to provide data consistency? (d)(a) the database administrator's(b) the user's(c) the application programmer's(d) the DBMS's6. A database is needed for which of the following application scenarios? (b)A video store that needs to keep track of data about members, about videos carried by the store, about videos rented by members, as well as data concerning borrow-date, return-date, and payment information.In the human resources department of a company, information about employees, their titles, their salaries and sick days, and about vacation days taken by each employee.A computer-simulated video game which needs to calculate and display, the physical (x, y) location of each actor in the game, the speed with which they are moving at the current instant, the direction in which they are moving, the action they are performing, the angle at which the game-player is viewing the scene.(a) I and III only(b) I and II only(c) I, II, and III(d) I only7.The physical storage structure will be _____ to the application programmer in a database approach, and will be _____ to the application programmer in a file system approach. (b)(a) visible, visible(b) hidden, visible(c) visible, hidden(d) hidden, hiddenMultiple-Choice Quiz 21. The foreign key in a table T1 _____ the same _____ as the corresponding primary key in table T2. (d)must have, nameneed not have, namemust have, domain(a) I, II, and III(b) I and II(c) I and III(d) II and III2. The degree of a table is the number of _____ in the table. (c)(a) keys(b) rows(c) columns(d) foreign keys3. The arity of a table is the number of _____ in the table. (c)(a) rows(b) foreign keys(c) columns(d) keys4. The cardinality of a table is the number of _____ in the table. (b)(a) keys(b) rows(c) columns(d) foreign keys5. Which of the following SQL statements can be used to add a row to a table? (c)(a) CREA TE(b) ADD(c) INSERT(d) APPEND6. The SQL clause to perform a set UNION operation is (b)(a) UNITE(b) UNION(c) COMBINE(d) MELD7. The SQL clause to perform a set difference operation is (b)(a) OMIT(b) EXCEPT(c) REJECT(d) DIFFER8. DDL is used to (c)(a) add contents to tables.(b) define the structure of database applications.(c) specify the structure of a database.(d) access the contents of tables.9. A deletion operation will _____ if the deletion leads to the violation of a referential integrity constraint. (a)(a) fail(b) crash the system(c) succeed with warning(d) succeed without warning10. The term query by example refers to (b)(a) a query for SQL examples(b) a visual query language developed by IBM(c) example SQL queries provided by other users that can be modified to suit current needs(d) example SQL queries provided by the DBMS that users can modify to suit their current needs11. What information is necessary when specifying the structure of a table? (d)(a) the name of the table and the amount of storage space to be allocated to the table(b) the name of the table and the names of the table's attributes(c) the name of the table, the names of the table's attributes, the data types of the table's attributes, the formats of the table's attributes, and the maximum number of rows that the table can have (d) the name of the table, the names of the table's attributes, the data types of attributes, and the formats of attributes12. What can be specified in the selection condition of a SELECT statement? (a)(a) a Boolean operation(b) the conditions under which the statement should be executed(c) the time at which the selection should be performed(d) an arithmetic operation13. Which of the following SQL statements can be used to modify just one row (out of many rows) in a table? (c)(a) ALTER(b) MODIFY(c) UPDA TE(d) CHANGE14. A deletion operation will _____ if the deletion leads to the violation of a referential integrity constraint. (c)(a) succeed with warning(b) succeed without warning(c) fail(d) crash the system15. Which of the following SQL statements can be used to create a relational table? (b)(a) APPEND(b) CREA TE(c) ADD(d) INSERT16. With Query By Example, a user enters a query by (b)(a) typing a syntactically correct SQL query that uses column and table names similar to the correct column and table names in a database(b) filling in skeleton tables of the database with examples of what is to be retrieved(c) placing SQL keywords, such as select, under the column names they want to retrieve(d) writing an English description of the data that the user needs17. DML is used to (d)(a) manipulate the structure of database applications.(b) specify the structure of a database.(c) add and delete tables.(d) add/modify/delete data in the database.18. A join operation joins _____ tables into _____. (a)(a) two, one(b) three, two(c) four, two(d) three, one//union/intersect/except参加运算的关系必须相容(即含有相同的属性集)19. A difference operation can be applied to tables that (b)(a) have the same column names(b) are union compatible(c) are the same size(d) have the same name20. Which of the following SQL statements can be used to remove a row from a table? (c)(a) REMOVE(b) ERASE(c) DELETE(d) DESTROYMultiple-Choice Quiz 31. In SQL, one function of the AS operator is to (c)(a) control the order in which a query’s rows are sorted(b) define the domain of an attribute(c) customize the names of columns in a query’s result(d) limit the cardinality of a relation2. When removing a table from the schema, using the RESTRICT option would (a)(a) remove the table if there are no references to it(b) remove the table and all other tables that the specified table refers to(c) remove the table and all references to it(d) recursively remove the table and all other tables that the removed table refers to3. In SQL, a database can be destroyed by which of the following? (a)(a) the command DROP SCHEMA(b) the command DELETE DA TABASE(c) the command DESTROY DA TABASE(d) a series of DESTROY TABLE commands4. When a string whose length is strictly less than n is entered as the value of a field whose SQL data type is V ARCHAR(n), the system responds by (b)(a) re-prompting for the entry of a string whose length is exactly n.(b) storing the string as is.(c) padding the end of the string with NULL characters to length n before storing it.(d) padding the end of the string with spaces to length n before storing it.5. In SQL, when destroying a database, the RESTRICT option removes (b)(a) everything in the specified database: the data, schema, etc.(b) the schema if the database has no data (empty tables)(c) the data and schema from the specified database, but not from related databases(d) the data but not the schema6. In SQL, a database can be created by which of the following? (d)(a) a series of CREA TE TABLE commands(b) the command ADD DA TABASE(c) the command INSERT DA TABASE(d) the command CREA TE SCHEMA7. In a FROM clause of a SELECT statement in SQL, a table can be aliased with which of the following operators? (b)(a) ALIAS(b) AS(c) RENAME(d) @8. In SQL, which of the following clauses can be used to sort results in ascending or descending order of attribute values? (c)(a) SORT(b) GROUP BY(c) ORDER BY(d) ARRANGE BY9. When specifying a selection criterion in SQL, attributes can be renamed with which of thefollowing operators? (d)(a) ALIAS(b) @(c) RENAME(d) AS10. In SQL, which of the following operators can be used to express searches that test for a range in a selection condition? (a)(a) BETWEEN(b) RANGE(c) START and END(d) FROM and TOMultiple-Choice Quiz 41. Which of the following is true about updateability of views? (a)(a) A view is updateable if it involves one table and contains a key.(b) A view is updateable if it involves multiple tables and no keys.(c) A view is updateable if it involves one table and does not contain a key.(d) A view is not updateable under any circumstance.2. A vertical view allows users access to (d)(a) only the system tables(b) only specific rows of the defining tables(c) only the user tables(d) only specific columns of the defining tables3. A horizontal view allows users access to (a)(a) only specific rows of the defining tables(b) only specific columns of the defining tables(c) only the system tables(d) only the base tables4. Consider two tables, Employee(EmpNo, Name, DeptNo) and Department(DeptNo, Name, Manager) with primary keys being EmpNo and DeptNo respectively. The DeptNo attribute of the Employee table has a NOT NULL constraint and is a foreign key that references the DeptNo attribute of the Department table. The Manager attribute of the Department table has a NOT NULL constraint and is a foreign key that references the EmpNo attribute of the Employee table. When the tables are empty, the only way to insert rows into the two tables is (d)(a) to use a transaction in NOT DEFERRABLE mode(b) to use a transaction either in DEFERRABLE mode or in NOT DEFERRABLE mode(c) not to use a transaction at all(d) to use a transaction in DEFERRABLE mode5. The SQL keyword _____ makes the modifications of the transaction permanent, while the SQL keyword _____ discards the modifications of the transaction. (b)(a) WRITE, ABORT(b) COMMIT, ROLLBACK(c) UPDA TE, SELECT(d) SA VE, CANCEL6. Which of the following commands can be used to give access permissions to a table? (a)(a) GRANT(b) AUTHORIZE(c) PERMIT(d) ALLOW7.Who can always give access permissions to a table? (b)(a) only the super-user(b) the owner of the table(c) the user of the table(d) only the database administrator (DBA)8. Which of the following commands can be used to remove access privileges associated with a table? (a)(a) REVOKE(b) DENY(c) RETRACT(d) REMOVE9. When is embedded SQL referred to as static SQL? (d)(a) when the SQL statements can never be changed(b) when the embedded SQL operates on the static part of the database(c) when the embedded SQL always returns the same set of results(d) when the embedded SQL is translated into DBMS calls at compile-time10. When is embedded SQL referred to as dynamic SQL? (a)(a) when the embedded SQL is translated into DBMS calls at run-time(b) when the embedded SQL operates on the dynamic part of the database(c) when the embedded SQL always returns different sets of results(d) when the SQL statements are changed in every run11. Which of the following is true about views being up to date? (a)(a) V iews are always up to date.(b) V iews can be automatically made up to date periodically by the system.(c) V iews are never up to date; there is always a lag time.(d) V iews are up to date only after the synchronization operation by the user.12. Which of the following referentially triggered actions are supported in SQL when a referential integrity constraint is violated? (a)SET NULLREJECTCASCADESET DEFAULT(a) I, III, and IV only(b) II and III only(c) I and IV only(d) I, II, and III only13. Which of the following is true about updateability of views? (c)(a) A view is not updateable if it involves one table and contains a key.(b) A view is updateable under all circumstances.(c) A view is not updateable if it involves aggregate functions and nested queries.(d) A view is not updateable under any circumstance.Multiple-Choice Quiz 51. In an ER model, what is a recursive relationship type? (d)(a) The type of relationship that does not belong anywhere(b) A never-ending type of relationship(c) The relationship type where the related entities are one and the same(d) The type of relationship between entities of one entity type2. In an ER model, the cardinality ratio of a relationship type is (b)(a) the number of instances of relationships of that relationship type(b) the number of relationships of that relationship type in which an entity can participate(c) the minimum number of entities that can participate in that relationship type(d) the number of entity types involved in that relationship type3. Which of the following is true about storage for derived attributes? (b)(a) Derived attributes must not be stored.(b) Derived attributes are usually not stored because they can be computed.(c) Derived attributes must be stored.(d) Derived attributes are usually stored because storage improves retrieval performance.4. A weak entity type implies a (c)(a) relationship with partial participation constraint(b) strong relationship type(c) relationship with total participation constraint(d) weak relationship type5.In the Entity-Relationship model, properties that characterize entities and relationships are modeled as (c)(a) weak entities(b) entity types(c) attributes(d) participation constraints6. In the Entity-Relationship model, a derived attribute is one (c)(a) that is composed of multiple atomic attributes(b) that may have multiple values simultaneously(c) whose value can be computed from the values of other attributes(d) that characterizes a relationship instead of an entity7. In an ER model, which of the following is true about a component attribute? (b)(a) A component attribute always contains other components.(b) A component attribute can be a composite attribute.(c) A component attribute is always atomic.(d) Component attributes must always be combined by an aggregation operation.8. In ER modeling, generalization is the process of generating (b)(a) entities out of attributes(b) superclasses out of subclasses(c) subclasses out of superclasses(d) attributes out of entities9. Which of the following is true about attributes in a relational model? (d)Attributes can be multi-valued.Attributes can be composite.(a) II only(b) Neither I nor II(c) I only(d) Both I and II10. When mapping from an ER model to a relational model, a strong entity is mapped into a (d)(a) row(b) column(c) key(d) table11. In the Entity-Relationship model, the degree of a relationship specifies which of the following?(d)(a) The cardinality ratio of the relationship(b) The number of attributes that characterize the relationship(c) The number of integrity constraints required to implement the relationship(d) The number of entities that participate in the relationship12. What is an identifying owner in an ER model? (b)(a) The entity upon which a strong entity's existence depends(b) The entity upon which a weak entity's existence depends(c) The relationship that identifies a strong entity's owner(d) The relationship that identifies a weak entity's ownerMultiple-Choice Quiz 61. Which of the following is a property (are properties) exhibited by good relational schemas? The use of null values in tuples (d)The grouping of as many attributes as possible into one main tableThe elimination of data redundancy to avoid update anomalies(a) II and III only(b) None(c) I and II only(d) III only2. Through normalization, update anomalies (c)(a) is usually left unchanged(b) can be minimized but not eliminated(c) can be eliminated(d) can be maximized3. Consider the following functional dependency.{A, B} -> {C}Regarding this dependency, which of the following statements is (are) true? (c)The values of C are uniquely determined by the values of A.The values of A are uniquely determined by the values of C.(a) I and II(b) I only(c) None(d) II only4. Which of the following problems can be caused by data redundancy in a relational schema? Inefficient use of space (a)Update anomalies and possible loss of dataInefficient use of processing time(a) I, II, and III(b) I and II only(c) II only(d) I and III only5. Through normalization, data redundancy (d)(a) can be minimized but not eliminated(b) are usually left unchanged(c) can be maximized(d) can be eliminated6. Consider a table with atomic attributes A, B, and C and the following functional dependencies.A -> BB -> CIf the primary key of this table is attribute A, then this relation satisfies which of the following normal forms? (c)FirstSecondThird(a) I, II and III(b) I only(c) I and II only(d) None7. For a relation to be in 3NF, it should not contain _____ attribute that is transitively dependent on _____. (a)(a) a non-primary key, the primary key(b) a primary key, a non-primary key(c) a primary key, a foreign key(d) a non-primary key, a foreign key8. The FD X -> Y is a full dependency in a relation R, if there is _____ attribute A that can be _____ X and the dependency still holds. (d)(a) at least one, removed from(b) at least one, added to(c) no, added to(d) no, removed from9. For a relation to be in 2NF, _____ attribute must be fully functionally dependent on _____. (b)(a) every alternate key, the primary key(b) every non-primary-key, the primary key(c) every non-key, at least one key(d) every non-key, every key10. The FD X -> Y is a partial dependency in a relation R, if there is _____ attribute A that can be _____ X and the dependency still holds. (c)(a) at least one, added to(b) no, removed from(c) at least one, removed from(d) no, added to11. Which of the following statements concerning normal forms is true? (b)(a) The lower the normal form number, the better the schema design is.(b) A relation that is in second normal form is also in first normal form.(c) Schemas that are in second normal form are considered the best.(d) Each normal form contains a state of independent properties, unrelated to other normal forms.Multiple-Choice Quiz 71. All changes made by a committed transaction can be recovered (d)(a) only if there have been no software failures(b) only if there have been no hardware failures(c) only if there have been no software AND no hardware failures(d) irrespective of whether there have been hardware or software failures2. Is it possible for a valid transaction to see the modified, yet uncommitted data of another valid transaction when the isolation level is set to SERIALIZABLE? (a)(a) It is not possible for a transaction to see the modified, yet uncommitted, data of another transaction, even if both transactions are working on the same data, and even if both transactions are concurrent.(b) It is possible for a transaction to see the modified, yet uncommitted, data of another transaction even if both transactions are not working on the same data, AND even if both transactions are NOT concurrent.(c) It is possible for a transaction to see the modified, yet uncommitted, data of another transaction only if both transactions work on the same data, AND both transactions are NOT concurrent.(d) It is possible for a transaction to see the modified, yet uncommitted, data of another transaction, only if both transactions work on the same data, AND both transactions are concurrent.3. A livelock occurs when (a)(a) a transaction is aborted and restarted repeatedly(b) a transaction holding a lock is aborted(c) 2 or more transactions wait indefinitely because each holds the data items of another(d) an aborted transaction holding a lock is restarted4. In a two-phase locking protocol, what happens during the growing phase? (d)(a) The transaction can acquire locks, and can release its locks.(b) The transaction cannot acquire locks, but can release its locks.(c) The transaction can acquire locks, and can release its locks as long as the number of acquired locks is greater than the number of released locks.(d) The transaction can acquire locks, but cannot release its locks.5. An exclusive lock on a data item represents permission to perform which of the operations, read and write, on the data item? (c)(a) Read only(b) Neither read nor write(c) Both read and write(d) Write only6. In a two-phase locking protocol, what happens during the shrinking phase? (a)(a) The transaction cannot acquire locks, but can release its locks.(b) The transaction can acquire locks, but cannot release its locks.(c) The transaction can acquire locks, and can release its locks.(d) The transaction can acquire locks, and can release its locks as long as the number of released locks is greater than the number of acquired locks.7. The strict two-phase locking protocol is _____ to implement. (c)(a) easier than most two-phase locking protocols(b) more difficult than most two-phase locking protocols(c) the easiest two-phase locking protocol(d) the most difficult two-phase locking protocol8. Force propagation policy _____ redo actions, and no-force propagation policy _____ redo actions. (a)(a) does not require, requires(b) requires, requires(c) requires, does not require(d) does not require, does not require9.Immediate update policy _____ undo actions, and deferred update policy _____ undo actions.(c)(a) does not require, requires(b) does not require, does not require(c) requires, does not require(d) requires, requires10. During recovery, in which of the following ways are the before and after images used by the undo and redo actions? (d)undo action uses the before imageundo action uses the after imageredo action uses the after imageredo action uses the before image(a) I, II, and III only(b) I, III, and IV only(c) I, II, III, and IV(d) I and III onlyMultiple-Choice Quiz 81. Which of the following are properties of a good hash function? (c)It should be computed efficiently.It should minimize the number of collisions by spreading keys as evenly and uniformly as possible.It should always use the Modulo (MOD) function.(a) I only(b) III only(c) I and II only(d) II only2. Where do heap files add new records? (c)(a) at random locations in the heap file(b) in the middle of the heap file(c) at the end of the heap file(d) at the beginning of the heap file3. Hashing exhibits the best performance for(a) range queries(b) ordering query results based on the key used for hashing(c) equality searches involving the key, provided the key is used for hashing(d) sequential scan of the entire table4. A sparse index contains entries for (a)(a) some records of a table(b) some fields of a table(c) all fields of a table(d) all records of a table5. A primary index _____ defined on a key field, and a secondary index _____ defined on a key field. (d)(a) need not be, should not be(b) should be, should not be(c) need not be, need not be(d) should be, need not be6. Each index entry in an index file contains (c)an indexing valuea pointer to the page where the record with the value appearsan indexing function(a) I only(b) I, II, and III(c) I and II only(d) III only7. A cylinder of a multi-platter hard disk consists of (b)(a) the outermost track(b) tracks with the same diameter(c) the innermost track(d) tracks with different diameters8. To improve the performance of a database, (d)(a) never use buffering when transferring data between secondary storage and main memory(b) never use hash files when deciding on an appropriate indexing structure(c) always use hash files when deciding on an appropriate indexing structure(d) minimize the amount of data transferred between secondary storage and main memory9. The term block transfer time refers to the amount of time it takes to (c)(a) load the address of a disk block from an index(b) move the read/write head to the appropriate track on the disk(c) read data from a disk(d) position the appropriate disk block under the read/write head10. The term blocking factor refers to the number of (c)(a) disk blocks that form a track(b) disk blocks that are on a hard disk drive platter(c) database records that can be stored on a disk block(d) cylinders on a hard disk drive11. How does chained overflow solve the problem of collisions in hashing? (d)(a) The first available empty bucket in a chained list of buckets is used.(b) The first available slot in the overflow area where slots are chained using a hash function is used.(c) The first available slot in a linked list of slots that is connected to the collision slot is used.(d) The first available slot in a linked list of overflow buckets that is connected to the hashed bucket is used.12. A secondary index is an index defined on a(n) _____ field. (a)(a) non-ordering(b) ordering(c) primary key(d) alternate key13. Which of the following can be used to measure hard disk drive performance? (b)Seek timeRotational latency。

数据库作业答案—ch2

A super key(超码) of an entity set is a set of one or more
Entity Sets
A database can be modeled as:
a collection of entities(实体), Relationship(联系) among entities.
An entity is an object that exists and is distinguishable from

元的) (or degree度 two).
Relationship sets may involve more than two entity sets.
E.g. Suppose employees of a bank may have jobs (responsibilities) at multiple branches, with different jobs at different branches. Then there is a ternary relationship set between entity sets employee, job and branch
2.2 Constraints(约束)
Mapping Cardinalities
Express the number of entities to which another
entity can be associated via a relationship set. Most useful in describing binary relationship sets. For a binary relationship set the mapping cardinality(映射的基数) must be one of the following types:
  1. 1、下载文档前请自行甄别文档内容的完整性,平台不提供额外的编辑、内容补充、找答案等附加服务。
  2. 2、"仅部分预览"的文档,不可在线预览部分如存在完整性等问题,可反馈申请退款(可完整预览的文档不适用该条件!)。
  3. 3、如文档侵犯您的权益,请联系客服反馈,我们会尽快为您处理(人工客服工作时间:9:00-18:30)。
相关文档
最新文档