目 录
一、引言 ........................................................................................................................................................................5
1.1 编写目的........................................................................................................................................................5
1.2 参考资料........................................................................................................................................................5
二、 需求规约............................................................................................................................................................6
2.1 业务描述..............................................................................................................................................................6
2.2 需求分析..............................................................................................................................................................6
三、 数据库环境说明................................................................................................................................................7
四、 数据库的命名规则............................................................................................................................................7
4.1 数据库对象命名规则..........................................................................................................................................7
4.2 数据项编码规则..................................................................................................................................................7
五、 逻辑设计............................................................................................................................................................8
5.1 ER 图 ....................................................................................................................................................................8
5.2 关系模型..............................................................................................................................................................8
六、 物理设计............................................................................................................................................................9
6.1 表汇总..................................................................................................................................................................9
6.2 表[1]:[ SUPPLIERS 表](供应商表)........................................................................................................................9
6.3 表[2]:[ PRODUCT 表](产品表) ...........................................................................................................................10
6.4 表[3]:[ SP 表](供应商产品供应表) ..................................................................................................................10
6.5 表[4]:[ ORDERS 表](订单表)..............................................................................................................................11
6.6 表[5]:[ PO 表](产品订购表)..............................................................................................................................12
6.7 表[6]:[ EMPLOYEE 表](雇员表) .........................................................................................................................12
6.8 表[7]:[ CUSTOMER 表](客户表).........................................................................................................................13
6.9 视图的设计......................................................................................................................................................13
6.10 存储过程的设计............................................................................................................................................14
6.11 触发器的设计................................................................................................................................................18
6.12 函数的设计....................................................................................................................................................18
七、 安全性设计......................................................................................................................................................19
7.1 防止用户直接操作数据库的方法..................................................................................................................19
7.1.1 用户标识和鉴定 ...........................................................................................................................................19
7.1.2 存取控制 .......................................................................................................................................................19
7.1.3 数据加密 .......................................................................................................................................................19
7.2 用户帐号密码的加密方法..............................................................................................................................19
7.3 角色与权限......................................................................................................................................................19
八、 数据库管理与维护说明..................................................................................................................................20
九、 总结..................................................................................................................................................................21