Initial commit
This commit is contained in:
14
script/sql/create/31.scada_element.sql
Normal file
14
script/sql/create/31.scada_element.sql
Normal file
@@ -0,0 +1,14 @@
|
||||
create type scada_model_type as enum ('JUNCTION', 'RESERVOIR', 'TANK', 'PIPE', 'PUMP', 'VALVE');
|
||||
|
||||
create type scada_element_status as enum ('OFF', 'ON');
|
||||
|
||||
create table scada_element
|
||||
(
|
||||
id text primary key
|
||||
, x float8 not null
|
||||
, y float8 not null
|
||||
, device_id text references scada_device(id)
|
||||
, model_id varchar(32) -- add constraint in API
|
||||
, model_type scada_model_type
|
||||
, status scada_element_status not null default 'OFF'
|
||||
);
|
||||
Reference in New Issue
Block a user