CREATE PROCEDURE dbo.GiftTokenUpdateStatus @AGiftTokenNumber VARCHAR(50), @ANewStatus INT AS
SET NOCOUNT ON

DECLARE @tmpGiftTokenNumber2 INT

SELECT @tmpGiftTokenNumber2 = GiftTokenNumber2
FROM GiftToken WITH (NOLOCK)
WHERE Id = @AGiftTokenNumber

INSERT INTO GiftToken (GiftTokenNumber, Status, GiftTokenNumber2) VALUES
(@AGiftTokenNumber, @ANewStatus, @tmpGiftTokenNumber2)