Item Purchase Error!

Results 1 to 11 of 11
  1. #1
    Proficient Member Drkidvictor is offline
    MemberRank
    Jul 2011 Join Date
    New JerseyLocation
    174Posts

    Item Purchase Error!

    Omfg omfg i deleted the keys in db and still get this error..
    hue.jpg


  2. #2
    Alpha Member Chrisss is offline
    MemberRank
    Feb 2012 Join Date
    Ask the Fox!Location
    1,660Posts

    Re: Item Purchase Error!

    Search for Anju's SQL script for buying items with 0 bounty.

  3. #3
    Asylum Gamers WickedsInferno is offline
    MemberRank
    Jun 2011 Join Date
    Deep In AsylumLocation
    394Posts

    Re: Item Purchase Error!

    Search For your dbo.spBuyBountyItem in your database and replace this ,


    With this
    Code:
    USE [GunzDB]
    GO
    /****** Object:  StoredProcedure [dbo].[spBuyBountyItem]    Script Date: 1/10/2013 3:36:39 AM ******/
    SET ANSI_NULLS ON
    GO
    SET QUOTED_IDENTIFIER ON
    GO
    ALTER PROC [dbo].[spBuyBountyItem]
    -- ALTER PROC dbo.spBuyBountyItem
    	@CID				INT,  
    	@ItemID				INT,
    	@ItemCount			INT,
    	@Price				INT,
    	@IsSpendableItem	INT,
    	@RentHourPeriod		INT = NULL	
    AS BEGIN
    	SET NOCOUNT ON
    	
    	DECLARE @Bounty INT;
    	DECLARE @OrderCIID INT;
    	DECLARE @Cnt INT;
    	
    	IF( @RentHourPeriod IS NULL ) BEGIN
    		SET @RentHourPeriod = 0;
    	END
    	
    	DECLARE @CurDate DATETIME;
    	SET @CurDate = GETDATE();
    
    	BEGIN TRAN ----------------------------	
    	
    		-- Àܾװ˻ç => Bounty °¨¼Ò      
    		UPDATE	dbo.Character 
    		SET		BP = BP - @Price 
    		WHERE	CID = @CID 
    		AND		(BP - @Price >= 0);
    		
    		IF( 0 <> @@ERROR OR 0 = @@ROWCOUNT ) BEGIN      
    			ROLLBACK TRAN
    			SELECT -1 AS 'Ret'
    			RETURN;
    		END      		
    		
    		IF( @IsSpendableItem = 1 ) BEGIN
    					
    			-- ÀÌ¹Ì °®°í ÀÖ´ÂÁö È®ÀÎÇØº»´Ù.
    			SELECT	@OrderCIID = CIID 
    			FROM	CharacterItem(NOLOCK) 
    			WHERE	CID = @CID 
    			AND		ItemID = @ItemID;
    		
    			-- ÀÌ¹Ì °®°í ÀÖÁö ¾Ê´Ù¸é »õ·Î Ãß°¡ÇØÁØ´Ù.
    			IF( @OrderCIID IS NOT NULL ) BEGIN
    			
    				UPDATE	dbo.CharacterItem				-- Item Ãß°¡
    				SET		Cnt = Cnt + @ItemCount
    				WHERE	CIID = @OrderCIID
    				AND		CID = @CID;
    				
    				IF( 0 <> @@ERROR OR 0 = @@ROWCOUNT ) BEGIN      
    					ROLLBACK TRAN
    					SELECT -2 AS 'Ret'
    					RETURN;
    				END
    										
    			END ELSE BEGIN
    			
    				INSERT INTO CharacterItem (CID, ItemID, RegDate, RentDate, RentHourPeriod, Cnt)
    				Values (@CID, @ItemID, @CurDate, @CurDate, @RentHourPeriod, @ItemCount)
    				
    				IF( 0 <> @@ERROR OR 0 = @@ROWCOUNT ) BEGIN      
    					ROLLBACK TRAN
    					SELECT -3 AS 'Ret'
    					RETURN;
    				END
    				
    				SELECT @OrderCIID = @@IDENTITY;	
    			END
    						
    		END
    		ELSE BEGIN
    				
    			INSERT dbo.CharacterItem (CID, ItemID, RegDate, RentDate, RentHourPeriod, Cnt)
    			Values (@CID, @ItemID, @CurDate, @CurDate, @RentHourPeriod, @ItemCount)
    			
    			SELECT @OrderCIID = @@IDENTITY;	
    			
    			IF( 0 <> @@ERROR OR 0 = @@ROWCOUNT ) BEGIN      
    				ROLLBACK TRAN
    				SELECT -4 AS 'Ret'
    				RETURN;
    			END
    						
    		END 
    		
    		-- Item ±¸¸Å·Î±× Ãß°¡      
    		INSERT INTO ItemPurchaseLogByBounty (ItemID, CID, Date, Bounty, CharBounty, Type)
    		VALUES (@ItemID, @CID, @CurDate, @Price, @Bounty, '±¸ÀÔ')
    		
    		IF( 0 <> @@ERROR OR 0 = @@ROWCOUNT ) BEGIN      
    			ROLLBACK TRAN
    			SELECT -5 AS 'Ret'
    			RETURN;
    		END
    		
    	COMMIT TRAN ----------------------------
    		
    	SELECT 0 AS 'Ret', @OrderCIID AS 'ORDERCIID'
    END
    
    
    ----------------------------------------------------------------------------------------------------------------------------------------
    -- º¹±¸ Äõ¸®
    /*
    DROP PROC spBuyBountyItem
    EXEC sp_rename 'BackUp_spBuyBountyItem', 'spBuyBountyItem'
    */

  4. #4
    Proficient Member Drkidvictor is offline
    MemberRank
    Jul 2011 Join Date
    New JerseyLocation
    174Posts

    Re: Item Purchase Error!

    I don't even have that dbo in my database bro.

  5. #5
    Alpha Member Chrisss is offline
    MemberRank
    Feb 2012 Join Date
    Ask the Fox!Location
    1,660Posts

    Re: Item Purchase Error!

    Look in Stored Procedures, it's there, this is what I mean, you don't look for things before you post, we cannot spoon feed you.

  6. #6
    Asylum Gamers WickedsInferno is offline
    MemberRank
    Jun 2011 Join Date
    Deep In AsylumLocation
    394Posts

    Re: Item Purchase Error!

    If you're to lazy to look for it, create a new table and past that.

  7. #7
    In Progress... FFXIV... Anju is offline
    MemberRank
    Oct 2010 Join Date
    Mist Ward 7 #38Location
    1,946Posts

    Re: Item Purchase Error!

    Ffs.
    GunzDB > Programmability > Stored Procedures > dbo.spBuyBountyItem

  8. #8
    Proficient Member Drkidvictor is offline
    MemberRank
    Jul 2011 Join Date
    New JerseyLocation
    174Posts

    Re: Item Purchase Error!

    It wasn't there! I am not lazy. I searched and it wasn't there >.>. I had to execute as a new stored procedure ...

    And it still says the same error >.>

  9. #9
    In Progress... FFXIV... Anju is offline
    MemberRank
    Oct 2010 Join Date
    Mist Ward 7 #38Location
    1,946Posts

    Re: Item Purchase Error!

    Are you even using the same version of files that should be with the server and database? For example, don't use 2008 database with Gunz 1.5 files (server/client).

    Otherwise, Check the server logs as well to see what is going on.

  10. #10
    Proficient Member Drkidvictor is offline
    MemberRank
    Jul 2011 Join Date
    New JerseyLocation
    174Posts

    Re: Item Purchase Error!

    I'm using 1.5 db the one chris sent me :I

  11. #11
    Enthusiast bhr is offline
    MemberRank
    Oct 2013 Join Date
    44Posts

    Re: Item Purchase Error!

    dbo.item -> keys -> delete keys O.O



Advertisement