Mysql創立通用裝備治理信息體系數據庫。本站提示廣大學習愛好者:(Mysql創立通用裝備治理信息體系數據庫)文章只能為提供參考,不一定能成為您想要的結果。以下是Mysql創立通用裝備治理信息體系數據庫正文
上面經由過程圖文並茂的方法給年夜家引見通用裝備治理信息體系數據庫的創立進程,詳細概況請看下文。
裝備表:id,稱號,種別,型號,投運日期,購入日期,制作單元,數目,計量單元,應用部分,裝置
所在,產物圖片,技巧數據,備注;
缺點表:id, 裝備id,缺點描寫,處置情形,處置人員;
變亂表:id,裝備id,變亂描寫,處置情形,處置人員;
維修種別表:id,種別稱號,維修內容,周期(天)
裝備種別表:id,種別稱號;
部分表:id,部分稱號;
裝備狀況表:id,狀況稱號
裝備狀況: 指定裝備的狀況,其狀況數據有:上線、封存、閒置、報廢、待修、備用
維修人員表:id,姓名,部分,職務,職稱;
備品備件表:id,稱號,數目,計量單元,用處,現有庫存量,最低庫存量;
對象表:id,稱號,數目,計量單元,用處;
維修記載表:id,維修種別id,裝備id,維修人員,維修情形,維修時光,所耗物料;
裝備巡檢表:id,裝備id,檢討日期,檢討人員,檢討情形,檢討方法;
create database devmng; show databases;
create table Equipment ( equipmentID int not null auto_increment, devtypeID int, devname varchar(50), modnum varchar(50), touyundate date, gourudate date, zhidaodw varchar(100), quantity int, unit varchar(8), useDepartment varchar(50), storePlace varchar(80), picture varchar(256), technicalData varchar(256), remark varchar(256), primary key (equipmentID) );
create table devbug ( bugID int not null auto_increment, devid int, bugcontent varchar(256), chuliqk varchar(100), chuliren varchar(80), primary key (bugID) ); create table devfault ( faultID int not null auto_increment, devid int, faultcontent varchar(256), chuliqk varchar(100), chuliren varchar(80), primary key (faultID) );
create table repairtype ( rtID int not null auto_increment, rtname varchar(24), rtcontent varchar(256), cycle int, primary key (rtID) ); create table devtype ( dtID int not null auto_increment, dtname varchar(36), primary key (dtID) ); create table part ( ptID int not null auto_increment, partname varchar(36), primary key (ptID) );
create table devstatus ( dsID int not null auto_increment, dsname varchar(12), primary key (dsID) ); insert into devstatus values (1,"上線"); insert into devstatus values (2,"封存"); insert into devstatus values (3,"閒置"); insert into devstatus values (4,"報廢"); insert into devstatus values (5,"待修"); insert into devstatus values (6,"備用");
create table repairpl ( rpID int not null auto_increment, ptid int, rpname varchar(24), zhiwu varchar(36), zhich varchar(36), primary key (rpID) ); create table bpbj ( bbID int not null auto_increment, bbname varchar(36), num int, unit varchar(8), purpose varchar(256), xianyounum int, minnum int, primary key (bbID) );
留意:use是症結字;不克不及用作字段名;
create table tools ( tID int not null auto_increment, tname varchar(36), num int, unit varchar(8), purpose varchar(256), primary key (tID) ); create table rprecords ( rrID int not null auto_increment, rtID int, equipmentID int, rpren varchar(100), rpcontent varchar(300), rpdate date, wuliao varchar(150), primary key (rrID) );
create table checkrecords ( crID int not null auto_increment, equipmentID int, checkdate date, checkren varchar(80), checkcontent varchar(100), checktype varchar(36), primary key (crID) ); ALTER TABLE Equipment ADD statusID int;
為裝備表增長一個裝備狀況列;
數據庫資本下載
http://pan.百度.com/s/1bpnx1YR
以上內容是針對Mysql創立通用裝備治理信息體系數據庫的全體內容,願望對年夜家有所贊助!