CREATE PROCEDURE [dbo].[SP_PDF_CANCELLAARCHIVIATO]
	@IdPdf AS BIGINT,
	@idProvenienza varchar(1) 
AS  
BEGIN
 BEGIN TRANSACTION    
declare @dtstamp as datetime
set @dtstamp = GETDATE()
 UPDATE ImagePdf SET [image] = NULL WHERE idPdf = @IdPdf
 INSERT INTO LogPdf 
 	SELECT @IdPdf,@dtstamp,4,@idProvenienza  
--**************************************************************************************
 COMMIT TRANSACTION	  
 select 1--@@ROWCOUNT
END