USE [site_fuchs] GO /****** Object: StoredProcedure [dbo].[ocms_recoverItem] Script Date: 02.12.2020 21:05:05 ******/ DROP PROCEDURE [dbo].[ocms_recoverItem] GO /****** Object: StoredProcedure [dbo].[ocms_recoverItem] Script Date: 02.12.2020 21:05:06 ******/ SET ANSI_NULLS ON GO SET QUOTED_IDENTIFIER ON GO -- ============================================= -- Author: -- Create date: -- Description: -- ============================================= CREATE PROCEDURE [dbo].[ocms_recoverItem] @ocms_iid bigint AS BEGIN SET NOCOUNT ON; SET IDENTITY_INSERT [dbo].[ocms_items] ON; insert into ocms_items ([ocms_iid] ,[parent_iid] ,[ocms_pid] ,[name] ,[view] ,[template_id] ,[hide] ,[order] ,[DateCreated] ,[DateModified]) select [ocms_iid] ,[parent_iid] ,[ocms_pid] ,[name] ,[view] ,[template_id] ,[hide] ,[order] ,[DateCreated] ,[DateModified] from ocms_archive__items where ocms_iid = @ocms_iid SET IDENTITY_INSERT [dbo].[ocms_items] OFF; SET IDENTITY_INSERT [dbo].[ocms_properties] ON; insert into ocms_properties ([ocms_pid] ,[ocms_iid] ,[key] ,[value] ,[locale] ,[DateCreated] ,[DateModified]) select [ocms_pid] ,[ocms_iid] ,[key] ,[value] ,[locale] ,[DateCreated] ,[DateModified] from ocms_archive__properties where ocms_iid = @ocms_iid SET IDENTITY_INSERT [dbo].[ocms_properties] OFF; END GO ALTER AUTHORIZATION ON [dbo].[ocms_recoverItem] TO SCHEMA OWNER GO