Everytime i relog in my character!
my pet skill that i gave him is gone!
Here is my Serverside Error text!
DB:{call sp_UpdatePetInven(2142,81,3,26,6,0,0,1,?)}
DB:42000, NativeError:8162, [Microsoft][SQL Server Native Client 11.0][SQL Server]The formal parameter "@nPetInvenSlotIndex" was not declared as an OUTPUT parameter, but the actual parameter passed in requested output.
Thank you in advance for the one who will give a Hints or Clue on how to solve this!
Have a blessed day ahead everyone!
up
up
up
USE [RanGame1]
GO
/****** Object: StoredProcedure [dbo].[sp_UpdatePetInven] Script Date: 05/22/2019 02:53:05 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
-- Return
-- DB_ERROR -1
-- DB_OK 0
ALTER PROCEDURE [dbo].[sp_UpdatePetInven]
@nChaNum int,
@nPetNum int,
@nPetInvenType int,
@nPetInvenMID int,
@nPetInvenSID int,
@nPetInvenCMID int,
@nPetInvenCSID int,
@nPetInvenAvailable int,
@nReturn int OUTPUT
AS
DECLARE
ERROR_var int,
Rowcount_var int
SET NOCOUNT ON
SET @nReturn = 0
BEGIN TRAN
-- @nPetInvenType = 1 : Accessory for A type
-- @nPetInvenType = 2 : Accessory for B type
-- @nPetInvenType = 3 : Skll
If @nPetInvenType=1 OR @nPetInvenType=2
BEGIN
UPDATE PetInven
SET PetInvenMID = @nPetInvenMID
, PetInvenSID = @nPetInvenSID
, PetInvenCMID = @nPetInvenCMID
, PetInvenCSID = @nPetInvenCSID
, PetInvenUpdateDate = getdate()
WHERE PetNum = @nPetNum And PetChaNum=@nChaNum
And PetInvenType = @nPetInvenType
END
Else If @nPetInvenType=3
BEGIN
UPDATE PetInven
SET PetInvenCMID = @nPetInvenCMID
, PetInvenCSID = @nPetInvenCSID
, PetInvenAvailable = @nPetInvenAvailable
, PetInvenUpdateDate = getdate()
WHERE PetNum = @nPetNum
And PetChaNum = @nChaNum
And PetInvenType = @nPetInvenType
And PetInvenMID = @nPetInvenMID
And PetInvenSID = @nPetInvenSID
END
-- PetInven Update Return Result
SELECT
ERROR_var =
ERROR,
Rowcount_var =
RowCOUNT
IF
ERROR_var <> 0
BEGIN
ROLLBACK TRAN
SET @nReturn = -1
END
ELSE
BEGIN
COMMIT TRAN
SET @nReturn = 0
END
IF
ERROR_var=0 AND
Rowcount_var=0)
BEGIN
BEGIN TRAN
INSERT INTO PetInven (PetNum, PetChaNum, PetInvenType, PetInvenMID, PetInvenSID, PetInvenCMID, PetInvenCSID, PetInvenAvailable)
Values (@nPetNum, @nChaNum, @nPetInvenType, @nPetInvenMID, @nPetInvenSID, @nPetInvenCMID, @nPetInvenCSID, @nPetInvenAvailable)
SELECT
ERROR_var =
ERROR,
Rowcount_var =
RowCOUNT
IF
ERROR_var <> 0 OR
Rowcount_var = 0
BEGIN
ROLLBACK TRAN
SET @nReturn = -1
END
ELSE
BEGIN
COMMIT TRAN
SET @nReturn = 0
END
END
SET NOCOUNT OFF
RETURN @nReturn