NOT IN USE SINCE 10.3-Patching

/*
select * from [MwusParentUss]
select * from [MwusConfiguration]
select * from MwusTargetGroup
*/


INSERT INTO [MwusParentUss]
([MwusParentUssID]
,[CatalogOnlySync]
,[LazySync]
,[ServerHostsPsfFiles]
,[MaxNumberOfUpdatesPerRequest]
,[Fqdn]
,[NewConfigAnchor]
,[LanguageUpdateList]
,[LastAuthorizationCookie]
,[LastCookie]
,[LastConfigAnchor]
,[LastSyncAnchor])
select
 1
,1
,1
,0
,100
,'10.35.200.173'
,null
,null
,null
,null
,null
,null
where not exists
(
	select * from [MwusParentUss]
	 where MwusParentUssID = 1
)
GO

/*
	INSERT INTO [MwusConfiguration]
*/

INSERT INTO [MwusConfiguration]([Key],[Value])
select 'wuident','https://www.update.microsoft.com/v11/3/legacy/windowsupdate/selfupdate/wuident.cab'
where not exists
(
	select * from MwusConfiguration
	 where [Key] = 'wuident'
)
GO


INSERT INTO [MwusConfiguration]([Key],[Value])
select 'UpdateCacheMaintenanceTimer','00:01'
where not exists
(
	select * from MwusConfiguration
	 where [Key] = 'UpdateCacheMaintenanceTimer'
)
GO

INSERT INTO [MwusConfiguration]([Key],[Value])
select 'CacheLastNeededTimeThresholdDays','60'
WHERE not exists
(
	select * from MwusConfiguration
	 where [Key] = 'CacheLastNeededTimeThresholdDays'
)
GO

INSERT INTO [MwusConfiguration]([Key],[Value])
select 'UpdateCacheEnabled','false'
where not exists
(
	select * from MwusConfiguration
	 where [Key] = 'UpdateCacheEnabled'
)
GO


INSERT INTO [MwusConfiguration]([Key],[Value])
select 'UpdateCachePath',''
where not exists
(
	select * from MwusConfiguration
	 where [Key] = 'UpdateCachePath'
)
GO



INSERT INTO [MwusConfiguration]([Key],[Value])
select 'selfupdate','http://ds.download.windowsupdate.com/v11/3/windowsupdate'
where not exists
(
	select * from MwusConfiguration
	 where [Key] = 'selfupdate'
)
go


INSERT INTO [MwusConfiguration]([Key],[Value])
select 'MaxExtendedUpdatesPerRequest','100'
where not exists
(
	select * from MwusConfiguration
	 where [Key] = 'MaxExtendedUpdatesPerRequest'
)
GO


INSERT INTO [MwusConfiguration]([Key],[Value])
select 'MetadataProcessChunkSize','200'
where not exists
(
	select * from MwusConfiguration
	 where [Key] = 'MetadataProcessChunkSize'
)
GO





INSERT INTO [MwusConfiguration]([Key],[Value])
select 'SyncMetadataOverride','false'
where not exists
(
	select * from MwusConfiguration
	 where [Key] = 'SyncMetadataOverride'
)
GO


INSERT INTO [MwusConfiguration]([Key],[Value])
select 'LastConfiguredHostName',''
where not exists
(
	select * from MwusConfiguration
	 where [Key] = 'LastConfiguredHostName'
)
GO



INSERT INTO [MwusConfiguration]([Key],[Value])
select 'IssuePatchNowRestarts','true'
where not exists
(
	select * from MwusConfiguration
	 where [Key] = 'IssuePatchNowRestarts'
)
GO



INSERT INTO [MwusConfiguration]([Key],[Value])
select 'MaxConcurrentSyncUpdates', '1000'
where not exists
(
	select * from MwusConfiguration
	 where [Key] = 'MaxConcurrentSyncUpdates'
)
GO




insert into MwusTargetGroup
(TargetGroupGuid, TargetGroupName)
select '00000000-7381-4E17-9C41-000000000000', 'All Computers'
where not exists
(
	select * from MwusTargetGroup
	 where TargetGroupGuid = '00000000-7381-4E17-9C41-000000000000'
)
GO


insert into MwusTargetGroup
(TargetGroupGuid, TargetGroupName)
select '00000000-9C41-4E17-7381-000000000000', 'Unassigned Computers'
where not exists
(
	select * from MwusTargetGroup
	 where TargetGroupGuid = '00000000-9C41-4E17-7381-000000000000'
)

