5、 逻辑结构设计
(一)CDM
(二)PDM
6、 物理结构设计
/*==============================================================*/ /* DBMS name: Microsoft SQL Server 2005 */ /* Created on: 2008-12-26 9:25:39 */ /*==============================================================*/ alter table 住户信息
drop constraint FK_住户信息_入住2_房间信息 go
alter table 周边设施
drop constraint FK_周边设施_对应_小区信息 go
alter table 房间信息
drop constraint FK_房间信息_入住_住户信息 go
alter table 房间信息
drop constraint FK_房间信息_对应的_楼宇信息 go
alter table 收费信息
drop constraint FK_收费信息_收费_小区信息 go
alter table 楼宇信息
drop constraint FK_楼宇信息_拥有的_小区信息 go
alter table 清洁管理
drop constraint FK_清洁管理_保洁_小区信息 go
alter table 维修
drop constraint FK_维修_维修_设备信息 go
alter table 维修
drop constraint FK_维修_维修2_小区信息 go
alter table 设备信息
drop constraint FK_设备信息_设备管理_小区信息 go
alter table 车位
drop constraint FK_车位_拥有_小区信息 go
if exists (select 1
from sysindexes
where id = object_id('住户信息') and name = '入住2_FK'
and indid > 0 and indid < 255) drop index 住户信息.入住2_FK go
if exists (select 1
from sysindexes
where id = object_id('周边设施') and name = '对应_FK' and indid > 0 and indid < 255) drop index 周边设施.对应_FK go
if exists (select 1
from sysindexes
where id = object_id('房间信息') and name = '入住_FK' and indid > 0 and indid < 255) drop index 房间信息.入住_FK go
if exists (select 1
from sysindexes
where id = object_id('房间信息') and name = '对应的_FK' and indid > 0 and indid < 255) drop index 房间信息.对应的_FK go
if exists (select 1
from sysindexes