当前位置:网站首页>Conceptual model design of the 2022 database of tyut Taiyuan University of Technology
Conceptual model design of the 2022 database of tyut Taiyuan University of Technology
2022-07-06 13:12:00 【Lala Lulu^_^】
Question 2
A description of a database is given in the question , Let's draw the database E-R chart , And indicate the attribute on the figure 、 The type of connection
(“ And indicate the attribute on the figure 、 The type of connection ” This sentence appears in the exam , Just treat him as if he didn't ; Because attributes are ellipses , Type is one-on-one , One to many , Many to many , These two things are paintings E-R Pictures must be drawn , In fact, from another perspective ,ER The attributes of a graph are divided into composite attributes 、 Multi valued attribute 、 Derived properties 、 Optional attribute , Contact properties , But we don't test so deep )
Talking about : This question should be a free question , I won't go into details , I believe everyone will , According to the requirements of the topic , Like high school Chinese reading , Find the entities in the topic ( Rectangle )、 Draw the properties next to the rectangle ( The ellipse ), Find out the relationship ( The diamond / The predicate in the question ) Then use according to the meaning of the topic 1、n、m Just connect , It should be noted that you should not use both adjacent many to many lines n Express , You have to use one n, One use m

Attach two examples to practice by yourself , If not, go back to the blog “ Question 1 E-R Graph to relational model ”, If you can't make a comment yet
example 1. Books in a library are stored in multiple libraries by category , For readers to borrow . There are several administrators in each library ( These administrators no longer manage other stacks ). Please design a database to store relevant information . among :
(1) The properties of the library include the library number 、 Location 、 Area etc. , The attributes of books include book numbers 、 Title 、 Publishing house, etc , The attributes of readers include reader number 、 full name 、 Unit, etc , The attributes of the administrator include employee number 、 Employee name and other attributes ; Please specify other properties by yourself .(2) The attributes that describe the borrowing relationship include lending date and return date
Try to draw the Library 、 The book 、 readers 、 Administrators and their contacts E-R chart ( It is required to indicate the relevant attributes and contact types ), And transform it into a relational pattern ( It is required to indicate the main code ).
Explain :
1. Library management database
(1) Library management database E-R The graph is as follows :

(2) The transformation to relational mode is as follows :
Library ( Library number , Address , area )
workers ( Employee number , full name , Age , Library number )
The book ( Book number , Title , author , Press. , Library number )
readers ( Reader number , full name , Company )
Borrow ( Reader number , Book number , Borrowing date , Return date )
2. Suppose a department's database contains the following information :
Employee information : Employee number 、 full name 、 Address and department .
Department Information : Department name 、 Manager's name 、 Telephone .
Product information : Product number 、 Product name 、 Price 、 model .
Manufacturer's information : Factory name 、 site of a factory 、 Fax .
In addition, it also includes information about the products sold by the Department and the products produced by the manufacturer .
Try to draw this database E-R chart ( It is required to indicate the relevant attributes and contact types ), And transform it into a relational pattern ( It is required to indicate the main code ).
Explain :
(1) database E-R The graph is as follows :

(2) The transformation to relational mode is as follows :
workers ( Employee number , full name , Address , Department name )
department ( Department name , The manager , Telephone )
product ( Product number , Product name , model , The unit price )
sales ( Department name , Product number )
Manufacturer ( Factory name , site of a factory , Fax )
production ( Product number , Factory name )
边栏推荐
- 分支语句和循环语句
- 十分钟彻底掌握缓存击穿、缓存穿透、缓存雪崩
- 121 distributed interview questions and answers
- TYUT太原理工大学2022软工导论大题汇总
- Small exercise of library management system
- [算法] 劍指offer2 golang 面試題2:二進制加法
- [rtklib] preliminary practice of using robust adaptive Kalman filter under RTK
- [算法] 剑指offer2 golang 面试题3:前n个数字二进制形式中1的个数
- 【快趁你舍友打游戏,来看道题吧】
- Redis介绍与使用
猜你喜欢
![[algorithm] sword finger offer2 golang interview question 4: numbers that appear only once](/img/f7/23ffc81ec8e9161c15d863c1a67916.png)
[algorithm] sword finger offer2 golang interview question 4: numbers that appear only once

架构师怎样绘制系统架构蓝图?
![[算法] 剑指offer2 golang 面试题12:左右两边子数组的和相等](/img/11/ee0628a68542236fc641966579a31a.png)
[算法] 剑指offer2 golang 面试题12:左右两边子数组的和相等
![[algorithm] sword finger offer2 golang interview question 13: sum of numbers of two-dimensional submatrix](/img/17/e7c9bfa867030af97eb66a7932c7e3.png)
[algorithm] sword finger offer2 golang interview question 13: sum of numbers of two-dimensional submatrix

一文搞定 UDP 和 TCP 高频面试题!
![[algorithm] sword finger offer2 golang interview question 9: subarray with product less than k](/img/65/fc3fb5a217a3b44f506b695af53e2c.png)
[algorithm] sword finger offer2 golang interview question 9: subarray with product less than k

Music playback (toggle & playerprefs)

堆排序【手写小根堆】

TYUT太原理工大学2022数据库大题之分解关系模式

What are the advantages of using SQL in Excel VBA
随机推荐
TYUT太原理工大学2022数据库题库选择题总结
TYUT太原理工大学2022软工导论大题汇总
染色法判定二分图
Tyut Taiyuan University of technology 2022 introduction to software engineering examination question outline
Alibaba cloud side: underlying details in concurrent scenarios - pseudo sharing
[algorithm] sword finger offer2 golang interview question 3: the number of 1 in the binary form of the first n numbers
图书管理系统小练习
[rtklib] preliminary practice of using robust adaptive Kalman filter under RTK
Alibaba cloud microservices (II) distributed service configuration center and Nacos usage scenarios and implementation introduction
Introduction and use of redis
[GNSS] robust estimation (robust estimation) principle and program implementation
雇佣收银员【差分约束】
C code implementation of robust estimation in rtklib's pntpos function (standard single point positioning spp)
MySQL backup -- common errors in xtrabackup backup
[algorithm] sword finger offer2 golang interview question 1: integer division
String class
继承和多态(上)
2022国赛Re1 baby_tree
[algorithm] sword finger offer2 golang interview question 10: subarray with sum K
162. Find peak - binary search