FUNDAMENTALS OF DATABASE SYSTEMS Fourth Edition phần 3

Một chuyên môn mà là thuộc tính xác định nghĩa hạn chế disjointness nếu thuộc tính được sử dụng để xác định vị thành viên là một giá trị. Hình minh họa trường hợp này, nơi mà các d trong vòng tròn là viết tắt cho tách rời. Chúng tôi cũng sử dụng các ký hiệu d để chỉ định | 198 Chapter 7 Relational Database Design by ER-and EER-to-Relational Mapping Table Correspondence between er and Relational Models ER Model Entity type 1 1 or 1 N relationship type M N relationship type n-ary relationship type Simple attribute Composite attribute Multivalued attribute Value set Key attribute Relational Model Entity relation Foreign key or relationship relation Relationship relation and two foreign keys Relationship relation and n foreign keys Attribute Set of simple component attributes Relation and foreign key Domain Primary or secondary key 1 N relationship type is involved a single join operation is usually needed. For a binary M N relationship type two join operations are needed whereas for n-ary relationship types n joins are needed to fully materialize the relationship instances. For example to form a relation that includes the employee name project name and hours that the employee works on each project we need to connect each EMPLOYEE tuple to the related PROJECT tuples via the WORKS-ON relation of Figure . Hence we must apply the EQUIJOIN operation to the EMPLOYEE and WORKS-ON relations with the join condition SSN ESSN and then apply another EQUIJOIN operation to the resulting relation and the PROJECT relation with join condition PNO PNUMBER. In general when multiple relationships need to be traversed numerous join operations must be specified. A relational database user must always be aware of the foreign key attributes in order to use them correctly in combining related tuples from two or more relations. This is sometimes considered to be a drawback of the relational data model because the foreign key primary key correspondences are not always obvious upon inspection of relational schemas. If an equijoin is performed among attributes of two relations that do not represent a foreign key primary key relationship the result can often be meaningless and may lead to spurious invalid data. For example the reader can try joining the .

Không thể tạo bản xem trước, hãy bấm tải xuống
TÀI LIỆU MỚI ĐĂNG
125    61    1    17-05-2024
Đã phát hiện trình chặn quảng cáo AdBlock
Trang web này phụ thuộc vào doanh thu từ số lần hiển thị quảng cáo để tồn tại. Vui lòng tắt trình chặn quảng cáo của bạn hoặc tạm dừng tính năng chặn quảng cáo cho trang web này.