초기 커밋.
This commit is contained in:
49
LFP_Manager/DB Schema/DB_SCHEMA_TABLE.sql
Normal file
49
LFP_Manager/DB Schema/DB_SCHEMA_TABLE.sql
Normal file
@@ -0,0 +1,49 @@
|
||||
/*
|
||||
* ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
|
||||
* Table Name : TInventoryData
|
||||
* Description : BMS Inventory Data
|
||||
* createAt : 2020.12.02
|
||||
* createBy : JK.Woo
|
||||
* ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
|
||||
*/
|
||||
drop table if exists TInventoryData;
|
||||
--drop sequence if exists inventory_data_seq;
|
||||
|
||||
--create sequence inventory_data_seq start 1;
|
||||
|
||||
create table TInventoryData
|
||||
(
|
||||
manufacture_date integer not null ,
|
||||
pcb_sn varchar(20) not null ,
|
||||
module_sn varchar(32) null ,
|
||||
create_date timestamp not null ,
|
||||
modify_date timestamp not null ,
|
||||
|
||||
primary key (pcb_sn)
|
||||
);
|
||||
create index inventory_data_idx1 on TInventoryData (pcb_sn);
|
||||
create index inventory_data_idx2 on TInventoryData (module_sn);
|
||||
|
||||
/*
|
||||
* ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
|
||||
* Table Name : TErrorLogTable
|
||||
* Description : Error Message Log Table
|
||||
* createAt : 2019.11.04
|
||||
* createBy : JK.Woo
|
||||
* ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
|
||||
*/
|
||||
drop table if exists TErrorLogTable;
|
||||
--drop sequence if exists module_group_seq;
|
||||
|
||||
--create sequence module_group_seq start 1;
|
||||
|
||||
create table TErrorLogTable
|
||||
(
|
||||
create_date timestamp not null ,
|
||||
pcb_sn varchar(20) not null ,
|
||||
module_sn varchar(32) null ,
|
||||
PROCESS varchar(20) not null ,
|
||||
ERROR_TYPE varchar(100) not null ,
|
||||
ERROR_MSG varchar(200) not null
|
||||
);
|
||||
|
||||
86
LFP_Manager/DB Schema/LOG_DB_SCHEMA_TABLE.sql
Normal file
86
LFP_Manager/DB Schema/LOG_DB_SCHEMA_TABLE.sql
Normal file
@@ -0,0 +1,86 @@
|
||||
/********************************** BATTERY VALUE TABLE **************************************************/
|
||||
|
||||
/*
|
||||
* ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
|
||||
* Table Name : TModuleValue
|
||||
* Description : Battery Module Value and Status Table
|
||||
* createAt : 2021.03.04
|
||||
* createBy : JK.Woo
|
||||
* ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
|
||||
*/
|
||||
drop table if exists TModuleValue;
|
||||
|
||||
create table TModuleValue
|
||||
(
|
||||
create_date timestamp not null ,
|
||||
module_no smallint not null ,
|
||||
model_name varchar(32) null ,
|
||||
module_sn varchar(32) null ,
|
||||
fw_ver varchar(10) null , -- "V2.4.1.4"
|
||||
comm_fail BOOLEAN null ,
|
||||
op_status smallint null ,
|
||||
alarm_status smallint null ,
|
||||
warning smallint null ,
|
||||
fault smallint null ,
|
||||
module_voltage NUMERIC null ,
|
||||
module_current NUMERIC null ,
|
||||
module_soc NUMERIC null ,
|
||||
module_soh NUMERIC null ,
|
||||
module_cyclecount NUMERIC null ,
|
||||
cv_diff NUMERIC null ,
|
||||
cell_voltage_01 NUMERIC null ,
|
||||
cell_voltage_02 NUMERIC null ,
|
||||
cell_voltage_03 NUMERIC null ,
|
||||
cell_voltage_04 NUMERIC null ,
|
||||
cell_voltage_05 NUMERIC null ,
|
||||
cell_voltage_06 NUMERIC null ,
|
||||
cell_voltage_07 NUMERIC null ,
|
||||
cell_voltage_08 NUMERIC null ,
|
||||
cell_voltage_09 NUMERIC null ,
|
||||
cell_voltage_10 NUMERIC null ,
|
||||
cell_voltage_11 NUMERIC null ,
|
||||
cell_voltage_12 NUMERIC null ,
|
||||
cell_voltage_13 NUMERIC null ,
|
||||
cell_voltage_14 NUMERIC null ,
|
||||
cell_voltage_15 NUMERIC null ,
|
||||
cell_voltage_16 NUMERIC null ,
|
||||
cell_voltage_17 NUMERIC null ,
|
||||
cell_voltage_18 NUMERIC null ,
|
||||
cell_voltage_19 NUMERIC null ,
|
||||
cell_voltage_20 NUMERIC null ,
|
||||
cell_voltage_21 NUMERIC null ,
|
||||
cell_voltage_22 NUMERIC null ,
|
||||
cell_voltage_23 NUMERIC null ,
|
||||
cell_voltage_24 NUMERIC null ,
|
||||
cell_voltage_25 NUMERIC null ,
|
||||
cell_voltage_26 NUMERIC null ,
|
||||
cell_voltage_27 NUMERIC null ,
|
||||
cell_voltage_28 NUMERIC null ,
|
||||
cell_voltage_29 NUMERIC null ,
|
||||
cell_voltage_30 NUMERIC null ,
|
||||
cell_voltage_31 NUMERIC null ,
|
||||
cell_voltage_32 NUMERIC null ,
|
||||
cell_voltage_33 NUMERIC null ,
|
||||
cell_voltage_34 NUMERIC null ,
|
||||
cell_voltage_35 NUMERIC null ,
|
||||
cell_voltage_36 NUMERIC null ,
|
||||
cell_voltage_37 NUMERIC null ,
|
||||
cell_voltage_38 NUMERIC null ,
|
||||
cell_voltage_39 NUMERIC null ,
|
||||
tp_diff NUMERIC null ,
|
||||
temperature_01 NUMERIC null ,
|
||||
temperature_02 NUMERIC null ,
|
||||
temperature_03 NUMERIC null ,
|
||||
temperature_04 NUMERIC null ,
|
||||
temperature_05 NUMERIC null ,
|
||||
temperature_06 NUMERIC null ,
|
||||
temperature_07 NUMERIC null ,
|
||||
temperature_08 NUMERIC null ,
|
||||
ext1_temp NUMERIC null ,
|
||||
ext2_temp NUMERIC null ,
|
||||
chg_option smallint null ,
|
||||
|
||||
primary key (create_date, module_no)
|
||||
);
|
||||
|
||||
create index ModuleValue_data_idx1 on TModuleValue (create_date);
|
||||
Reference in New Issue
Block a user