Having issues with an SP that I'm working on and for the life of me I can't understand why only the first character works just fine, but the second character doesn't. That LoginStatus will change, but not StaffStatus. Any ideas?
USE [PS_GameData]
GO
/****** Object: StoredProcedure [dbo].[Verify_StaffStatus] Script Date: 12/10/2013 12:32:40 PM ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
ALTER Proc [dbo].[Verify_StaffStatus]
AS
SET NOCOUNT ON
DECLARE @UserUID int
DECLARE @UID varchar (18)
DECLARE @CharID int
DECLARE @Event1 tinyint
DECLARE @Event2 tinyint
DECLARE @LoginStatus tinyint
DECLARE @StaffStatus tinyint
--
SELECT @UserUID=UserUID, @LoginStatus=LoginStatus FROM Chars WHERE CharID = @CharID
--
IF @CharID = 2050
BEGIN
UPDATE Chars SET StaffStatus = 1 WHERE CharID=@CharID
END
ELSE
IF @CharID = 4
BEGIN
UPDATE Chars SET StaffStatus = 1 WHERE CharID=@CharID
END
All of this is continued from the addon of the LoginStatus script for the online chars script found