数据库设计ER
2016-11-04 10:57:05 0 举报
实体-关系(ER)模型是一种用于数据库设计的常用工具,它通过表示现实世界中的对象和它们之间的关系来简化数据库设计过程。在ER模型中,实体被表示为矩形,而关系则被表示为连接实体的菱形。ER模型的主要目标是确保数据库结构能够准确地反映现实世界中的数据和关系。为了实现这一目标,设计师需要仔细考虑实体的属性和关系的性质,并根据这些信息创建相应的ER图。总之,ER模型是一种强大的数据库设计工具,它能够帮助设计师更好地理解数据需求,并创建一个高效、可靠的数据库结构。
作者其他创作
大纲/内容
club_launch
value: clid int not nullvalue: uid int not null
activity_involvement
value: aid int not nullvalue: uid int not null
club
primary key: clid int auto_incrementvalue: title varchar(255) not nullvalue: descriptiont textvalue: startdate datevalue: wathcingCnt bigint default 0value: managerCnt bigint default 0value: levelRestriction bigint
track
primary key: tid int auto_incrementvalue: title varchar(255) not nullvalue: content textvalue: date datevalue: agreeCnt bigint default 0foreign key: uid
trackReview
primary key: trid int auto_incrementvalue: content textvalue: date datevalue: reviewerid bigintforeign key: tidforeign key: uid
clubTopic
primary key: cltid int auto_incrementvalue: title varchar(255) not nullvalue: content textvalue: date datevalue: levelRestriction bigintforeign key uid
friendNews
primary key: fnid int auto_incrementforeign key: fidvalue: content textvalue: date date
activity_launch
sport_data
primay key: did int auto_incrementvalue: runmiles bigint default 0value: stairs bigint default 0value: stepCnt bigint default 0value: energy bigint defalut 0value: joiningTime bigint default 0value: totalRun bigint default 0value: totalStairs bigint default 0value: totalEnergy bigint default 0value: totalStepCnt bigint default 0value: runAnalysis textvalue: stairAnalysis textvalue: energyAnalysis textvalue: coachOverview textvalue: doctorOverview textvalue: date dateforeign key: uid
clubTopicReview
primary key: cltrid int auto_incrementvalue: content textvalue: date datevalue: levelRestriction bigintforeign key uid
hobby
primary key: hid intvalue: content textforeign key: uid
friend
primary key: fid int auto_incrementforeign key: uidvalue: oid(origin user id)
activity
primary key: aid int auto_incrementvalue: title varchar(255) not nullvalue: content textvalue: startdate datevalue: enddate datevalue: involvementCnt bigint default 0value: laucherCnt bigint default 0value: state bigint
person_data
primay key: did int auto_incrementvalue: height bigint default 0value: weight bigint default 0value: fatrate float default 0value: date dateforeign key: uid
trackAgree
primary key: taid int auto_incrementvalue: date datevalue: agreerid intforeign key: tidforeign key: uid
user
primary key: uid int auto_incrementvalue: birthday varchar(255)value: location varchar(255)value: portrait textvalue: nickname varchar(255) not nullvalue: email_address varchar(255) not nullvalue: password text not nullvalue: motto textvalue: couchid int default -1value: doctorid int default -1value: rightLevel intvalue: gender int
0 条评论
下一页