# ER Model vs Relational model ###### tags: `資料庫` ## 資料庫 的 ER Model 和 關聯模型不一樣 名詞翻譯 ER Model(Entity–relationship model):ER 模型,實體關聯模型 relational model:關聯模型圖 database schema:資料庫結構 ## 各自的用途 ### 資料庫結構 包含各種schema(結構),涵蓋 資料表結構、檢視表結構、預存程序、函式索引...等等,不包含資料內容,但也不僅限於資料表結構 ### 關聯模型圖 relational model 關聯模型圖是描述資料庫中,**資料表** 之間的關係,會將資料表連線,並且標示主鍵(Primary keys)、外來鍵(Foeign keys)  ### 實體關聯圖 ER model ER Model 是用來描述實體與實體之間關聯的模型圖。 實體(Entity)表示一個物件。實體可以成是名詞,如電腦、雇員、歌曲、數學定理。 關聯則是描述兩個或更多實體相互之間透過什麼方式關聯。關聯可以想像成是動詞。 * 公司和電腦之間有**擁有**關聯 * 雇員和部門之間有**管理**關聯 * 演員和歌曲之間有**表演**關聯 * 在數學家和定理之間有**證明**關聯。 實體繪製為矩形,聯絡繪製為菱形。  ER model 一定會有一些表示用的符號,這邊列出簡略範例  完整的 er model 範例  ## 在oracle產生圖 * Oracle SQL Developer 產生關聯模型 https://stackoverflow.com/questions/19275848/how-to-export-image-of-relational-model-in-oracle-sql-data-modeler * Oracle SQL Developer 產生ER Model 圖 https://stackoverflow.com/questions/6580529/how-to-generate-an-entity-relationship-er-diagram-using-oracle-sql-developer ## 影片 用Oracle Sql Developer產生資料庫關聯圖 https://www.youtube.com/watch?v=2fPP_u_Nzyw& [https://youtu.be/2fPP_u_Nzyw](https://youtu.be/2fPP_u_Nzyw) ## 影片 用PLSQL產生資料庫關聯圖 https://www.youtube.com/watch?v=2fPP_u_Nzyw&t=3m8s [https://youtu.be/2fPP_u_Nzyw?t=3m8s](https://youtu.be/2fPP_u_Nzyw?t=3m8s) ## 參考文獻 * ER Model 實體關係圖 http://cc.cust.edu.tw/~ccchen/doc/db_03.pdf * ER模型 https://zh.wikipedia.org/wiki/ER%E6%A8%A1%E5%9E%8B * 關聯模型 https://zh.wikipedia.org/wiki/%E5%85%B3%E7%B3%BB%E6%A8%A1%E5%9E%8B https://stackoverflow.com/questions/17641134/what-is-different-between-er-diagram-and-database-schema * Difference Between E-R Model and Relational Model in DBMS https://techdifferences.com/difference-between-e-r-and-relational-model-in-dbms.html
×
Sign in
Email
Password
Forgot password
or
Sign in via Google
Sign in via Facebook
Sign in via X(Twitter)
Sign in via GitHub
Sign in via Dropbox
Sign in with Wallet
Wallet (
)
Connect another wallet
Continue with a different method
New to HackMD?
Sign up
By signing in, you agree to our
terms of service
.