005.Shutdown process tables
parent
4be57b3ae3
commit
43dddcf59f
|
@ -0,0 +1,32 @@
|
|||
if not exists (select top 1 1 from sys.objects where name = 'ShutdownType' and type = 'U')
|
||||
begin
|
||||
create table ShutdownType
|
||||
(
|
||||
ShutdownTypeId int identity(1, 1) constraint PK_ShutdownType primary key,
|
||||
ShutdownTypeCode varchar(50),
|
||||
ShutdownTypeName varchar(130)
|
||||
)
|
||||
end
|
||||
go
|
||||
|
||||
if not exists (select top 1 1 from ShutdownType)
|
||||
begin
|
||||
insert into ShutdownType (ShutdownTypeCode, ShutdownTypeName)
|
||||
select 'NETWORK_RESURRECTOR_SERVER', 'Network resurrector server' union
|
||||
select 'NETWORK_RESURRECTOR_AGENT', 'Network resurrector agent'
|
||||
end
|
||||
|
||||
if not exists (select top 1 1 from sys.objects where name = 'ShutdownConfiguration' and type = 'U')
|
||||
begin
|
||||
create table ShutdownConfiguration
|
||||
(
|
||||
ConfigurationId int identity(1, 1) constraint PK_ShutdownConfiguration primary key,
|
||||
MachineId int constraint FK_ShutdownConfiguration_Machine foreign key references Machine(MachineId),
|
||||
ShutdownTypeId int constraint FK_ShutdownConfiguration_ShutdownType foreign key references ShutdownType(ShutdownTypeId),
|
||||
AgentPort int,
|
||||
[Default] bit,
|
||||
[Disabled] bit constraint DF_ShutdownConfiguration_Disabled default 0,
|
||||
[Description] varchar(2000)
|
||||
)
|
||||
end
|
||||
go
|
Loading…
Reference in New Issue