IF OBJECT_ID('[DREAM].[DimDreamBranche]','U') IS NOT NULL
BEGIN
SET IDENTITY_INSERT [DREAM].[DimDreamBranche] ON 
IF NOT EXISTS (SELECT 'T' FROM [DREAM].[DimDreamBranche] WHERE [DimDreamBrancheID] = -1 )
  INSERT INTO [DREAM].[DimDreamBranche]([DimDreamBrancheID]) VALUES (-1)
UPDATE [DREAM].[DimDreamBranche] SET
   [BrancheKode] = -1
	,[Branche] = 'Ingen kendt beskæftigelse'
	,[Branche127] = 'Ingen kendt beskæftigelse'
	,[Branche38] = 'Ingen kendt beskæftigelse'
	,[Branche21] = 'Ingen kendt beskæftigelse'
	,[Branche10] = 'Ingen kendt beskæftigelse'
	,[SYS_KommuneId] = 999
   WHERE [DimDreamBrancheID] = -1
SET IDENTITY_INSERT [DREAM].[DimDreamBranche] OFF 
END
GO
