某宾馆客房管理系统(2)

2019-04-09 08:34

4.数据库逻辑数据模型设计

此处根据数据库概念数据模型和数据库概念模型向关系数据库模型转换的规则,生成出系统的数据库逻辑数据模型。

5. 数据库物理数据模型设计

此处根据数据库概念数据模型生成数据库物理数据模型后,截图粘贴到此处。

6.建立数据库的SQL代码

if exists(select 1 from sys.sysforeignkey where role='FK_ENTITY_6_RELATIONS_客户') then

alter table Entity_6

delete foreign key FK_ENTITY_6_RELATIONS_客户 end if;

if exists(select 1 from sys.sysforeignkey where role='FK_客户_RELATIONS_客房') then alter table 客户

delete foreign key FK_客户_RELATIONS_客房 end if;

if exists(select 1 from sys.sysforeignkey where role='FK_客户_RELATIONS_ENTITY_8')

then

alter table 客户

delete foreign key FK_客户_RELATIONS_ENTITY_8 end if;

if exists(select 1 from sys.sysforeignkey where role='FK_客户_RELATIONS_ENTITY_9') then

alter table 客户

delete foreign key FK_客户_RELATIONS_ENTITY_9 end if;

if exists(select 1 from sys.sysforeignkey where role='FK_客户住宿_RELATIONS_客房') then

alter table 客户住宿

delete foreign key FK_客户住宿_RELATIONS_客房 end if;

if exists(select 1 from sys.sysforeignkey where role='FK_客房_RELATIONS_前台') then alter table 客房

delete foreign key FK_客房_RELATIONS_前台 end if;

if exists(select 1 from sys.sysforeignkey where role='FK_客房_RELATIONS_ENTITY_7') then

alter table 客房

delete foreign key FK_客房_RELATIONS_ENTITY_7 end if;

if exists(select 1 from sys.sysforeignkey where role='FK_客房_RELATIONS_ENTITY_1') then

alter table 客房

delete foreign key FK_客房_RELATIONS_ENTITY_1 end if;

drop index if exists Entity_10.Entity_10_PK;

drop table if exists Entity_10;

drop index if exists Entity_6.Relationship_7_FK;

drop index if exists Entity_6.Entity_6_PK;

drop table if exists Entity_6;

drop index if exists Entity_7.Entity_7_PK;

drop table if exists Entity_7;

drop index if exists Entity_8.Entity_8_PK;

drop table if exists Entity_8;

drop index if exists Entity_9.Entity_9_PK;

drop table if exists Entity_9;

drop index if exists 前台.前台_PK;

drop table if exists 前台;

drop index if exists 客户.Relationship_5_FK;

drop index if exists 客户.Relationship_4_FK;

drop index if exists 客户.Relationship_3_FK;

drop index if exists 客户.客户_PK;

drop table if exists 客户;

drop index if exists 客户住宿.Relationship_6_FK;

drop index if exists 客户住宿.客户住宿_PK;

drop table if exists 客户住宿;

drop index if exists 客房.Relationship_8_FK;

drop index if exists 客房.Relationship_2_FK;

drop index if exists 客房.Relationship_1_FK;

drop index if exists 客房.客房_PK;

drop table if exists 客房;

/*==============================================================*/ /* Table: Entity_10 */ /*==============================================================*/ create table Entity_10 (

Attribute_34 char(10) not null, Attribute_35 char(10) null,


某宾馆客房管理系统(2).doc 将本文的Word文档下载到电脑 下载失败或者文档不完整,请联系客服人员解决!

下一篇:工程技术研究中心可行性研究报告

相关阅读
本类排行
× 注册会员免费下载(下载后可以自由复制和排版)

马上注册会员

注:下载文档有可能“只有目录或者内容不全”等情况,请下载之前注意辨别,如果您已付费且无法下载或内容有问题,请联系我们协助你处理。
微信: QQ: