名称数据类型不为空采购表编号IntegerTRUE商品编号IntegerTRUE采购地址Characters TRUE采购日期Date & TimeTRUE主码TRUEFALSEFALSEFALSE c: 供货表
名称数据类型不为空供货表编号IntegerTRUE商品编号IntegerTRUE供货商编号IntegerTRUE供货日期Date & TimeTRUE主码TRUEFALSEFALSEFALSE d: 客户订单表
名称数据类型不为空订单编号IntegerTRUE订单类型Characters (20TRUE商品编号IntegerTRUE订单日期Date & TimeTRUE客户编号IntegerTRUE主码 ITRUEFALSEFALSEFALSEFALSE e: 库存表
名称数据类型不为空库存表编号IntegerTRUE库存日期Date & TimeTRUE管理员编号IntegerTRUE商品编号IntegerTRUE主码TRUEFALSEFALSEFALSE f: 统计报表
名称数据类型不为空报表编号IntegerTRUE报表类型Characters TRUE报表日期Date & TimeTRUE部门编号1IntegerTRUE
主码TRUEFALSEFALSEFALSE 6. 逻辑模型设计
1:PDM图:
订单表业务部门部门编号1int
七:代码设计
/*==============================================================*/ /* DBMS name: Microsoft SQL Server 2000 */ /* Created on: 2011-1-12 16:51:34 */
/*==============================================================*/
alter table Relationship_18
drop constraint FK_RELATION_RELATIONS_供货商 go
alter table Relationship_18
drop constraint FK_RELATION_RELATIONS_财务结算表 go
alter table Relationship_19
drop constraint FK_RELATION_RELATIONS_客户 go
alter table Relationship_19
drop constraint FK_RELATION_RELATIONS_财务结算表 go
alter table Relationship_5
drop constraint FK_RELATION_RELATIONS_业务部门 go
alter table Relationship_5
drop constraint FK_RELATION_RELATIONS_采购员 go
alter table Relationship_6
drop constraint FK_RELATION_RELATIONS_采购员 go
alter table Relationship_6
drop constraint FK_RELATION_RELATIONS_采购表 go
alter table Relationship_7
drop constraint FK_RELATION_RELATIONS_供货商 go
alter table Relationship_7
drop constraint FK_RELATION_RELATIONS_采购表 go
alter table Relationship_8
drop constraint FK_RELATION_RELATIONS_供货商 go
alter table Relationship_8
drop constraint FK_RELATION_RELATIONS_供货表 go
alter table 供货表
drop constraint FK_供货表_RELATIONS_库存管理员 go
alter table 供货表
drop constraint FK_供货表_RELATIONS_财会部门 go
alter table 客户
drop constraint FK_客户_RELATIONS_客户 go
alter table 客户
drop constraint FK_客户_RELATIONS_销售部门 go
alter table 库存表
drop constraint FK_库存表_RELATIONS_库存管理员 go
alter table 统计报表
drop constraint FK_统计报表_RELATIONS_业务部门 go
alter table 订单表
drop constraint FK_订单表_RELATIONS_客户 go
alter table 订单表
drop constraint FK_订单表_RELATIONS_客户 go
alter table 订单表
drop constraint FK_订单表_RELATIONS_业务部门 go
alter table 财务结算表
drop constraint FK_财务结算表_RELATIONS_财会部门 go
alter table 采购表
drop constraint FK_采购表_RELATIONS_财会部门 go
alter table 销售部门
drop constraint FK_销售部门_RELATIONS_销售部门 go
alter table 销售部门
drop constraint FK_销售部门_RELATIONS_库存表 go
if exists (select 1
from sysindexes
where id = object_id('Relationship_18') and name = 'Relationship_22_FK' and indid > 0 and indid < 255)
drop index Relationship_18.Relationship_22_FK go
if exists (select 1
from sysindexes
where id = object_id('Relationship_18') and name = 'Relationship_23_FK' and indid > 0 and indid < 255)
drop index Relationship_18.Relationship_23_FK go
if exists (select 1
from sysindexes
where id = object_id('Relationship_19') and name = 'Relationship_24_FK' and indid > 0 and indid < 255)
drop index Relationship_19.Relationship_24_FK go
if exists (select 1
from sysindexes
where id = object_id('Relationship_19') and name = 'Relationship_25_FK' and indid > 0 and indid < 255)
drop index Relationship_19.Relationship_25_FK go
百度搜索“77cn”或“免费范文网”即可找到本站免费阅读全部范文。收藏本站方便下次阅读,免费范文网,提供经典小说综合文库物流配送系统数据库设计(SQL)(4)在线全文阅读。
相关推荐: