Download presentation
Presentation is loading. Please wait.
1
中央大學。范錚強 1 從 ER 到 Logical Schema 國立中央大學 資訊管理系 范錚強 2002
2
中央大學。范錚強 2 準備 Logical Schema 資料模型和流程模型的整合 充實、調整資料模型 設計關連式資料庫 Logical Schema
3
中央大學。范錚強 3 設計關連式資料庫 Logical Schema For each entity type: Each Entity type becomes a Table Every attribute becomes a column The identifying attribute for the entity type becomes the key for the Table For each m-n relationship type Each m-n relationship type becomes a Table Every attribute becomes a column The identifying attribute of the associated entity types becomes the compound keys
4
中央大學。范錚強 4 資料模型和流程模型的整合 修訂模式 修改 DFD 中的 data store ,消除所有「迷糊帳」 所有 data store 相對到相關的實體或關係 建立資料典 DD:Data Dictionary 平衡 Balancing 原則 Every data flow and data store must be defined in the DD, Vice Versa Every data store must correspond to an entity or relationship type Object names in the DD, ERD and DFD must match DD entries must apply to both the DFD and ERD model
5
中央大學。范錚強 5 資料模型、邏輯資料庫設計、實 體資料庫設計 Process E-R data model --> Logical database design --> physical database design ANSI SPARC three tier DB architecture Enterprise views User views Physical views Physical Enterprise user
6
中央大學。范錚強 6 充實、調整資料模型 Attributing and Refining Attributing all entity and relationship types Eliminate all multi-valued attributes with appropriate relationships Identify an identifying attributes for each entity type and and any compound relationship
7
中央大學。范錚強 7 設計關連式資料庫 Logical Schema For each entity type: Each Entity type becomes a Table Every attribute becomes a column The identifying attribute for the entity type becomes the key for the Table For each m-n relationship type Each m-n relationship type becomes a Table Every attribute becomes a column The identifying attribute of the associated entity types becomes the compound keys
8
中央大學。范錚強 8 關連式資料庫 Logical Schema (2) For each 1-n relationship type Same as m-n relationship Only the n-side identifier becomes the key, the 1-side identifier becomes a non-key column For each 1-1 relationship type Same as 1-n relationship Pick the identifier from the appropriate associated entity type as the key, the other a non-key column
9
中央大學。范錚強 9 關連式資料庫 Logical Schema (3) For each compound entity type For the compound entity types that do not have its own identifier, same as relationship Otherwise, use the identifier as the key, and take the identifying attribute of the associated entity types as non-key columns
10
中央大學。范錚強 10 其他限制 在 Compound Entity 中﹐若有任何相關的 entity type 的 identifier 必須相同﹐將相關的 key 去除 若有其他的限制﹐加入到 DBMS 中﹐資料的 integrity 或 referential constraints 中
11
中央大學。范錚強 11 實體資料庫設計 可考慮將單一欄位的 Table 取消 Referential constraints Domain specification 深入了解 data behavior 合併或分解 Tables Examine the properties and behavior of tables and data Combine tables with the same key or same partial keys as appropriate (may result in lower normal forms) Split a Table into multiple tables, to maximize operational efficiency
Similar presentations
© 2025 SlidePlayer.com. Inc.
All rights reserved.