临时提交

This commit is contained in:
648540858
2024-12-23 07:20:48 +08:00
parent 825daad355
commit 19453f7ca9
17 changed files with 101 additions and 59 deletions

View File

@@ -147,8 +147,8 @@ create table wvp_device_channel
gb_svc_space_support_mod integer,
gb_svc_time_support_mode integer,
record_plan_id integer,
data_type integer,
data_device_id integer,
data_type integer not null,
data_device_id integer not null,
constraint uk_wvp_device_channel_unique_data unique (data_type, data_device_id),
constraint uk_wvp_unique_channel unique (gb_device_id)
);

View File

@@ -163,8 +163,8 @@ create table wvp_device_channel
gb_svc_space_support_mod integer,
gb_svc_time_support_mode integer,
record_plan_id integer,
data_type integer,
data_device_id integer,
data_type integer not null,
data_device_id integer not null,
constraint uk_wvp_device_channel_unique_data unique (data_type, data_device_id),
constraint uk_wvp_unique_channel unique (gb_device_id)
);

View File

@@ -3,10 +3,10 @@
*/
alter table wvp_device_channel
add data_type integer;
add data_type integer not null;
alter table wvp_device_channel
add data_device_id integer;
add data_device_id integer not null;
update wvp_device_channel wdc INNER JOIN
(SELECT device_db_id from wvp_device_channel where wdc.id = id and device_db_id is not null ) ct

View File

@@ -3,10 +3,10 @@
*/
alter table wvp_device_channel
add data_type integer;
add data_type integer not null;
alter table wvp_device_channel
add data_device_id integer;
add data_device_id integer not null;
update wvp_device_channel wdc
set data_type = 1, data_device_id = (SELECT device_db_id from wvp_device_channel where device_db_id is not null and id = wdc.id ) where device_db_id is not null;