Register for your free account! | Forgot your password?

Go Back   elitepvpers > MMORPGs > Rappelz > Rappelz Private Server
You last visited: Today at 17:45

  • Please register to post and access all features, it's quick, easy and FREE!

 

Stored Procedure db.smp_check_purchased_item?

Reply
 
Old   #1
 
elite*gold: 0
Join Date: Jun 2013
Posts: 6
Received Thanks: 2
Stored Procedure db.smp_check_purchased_item?

I've come across an error on the Captain Herlock server while logging on my character. This is the error I get:

Code:
DB COM ERROR(Thread:2, HRESULT:80040E37, GUID:0C733A63-2A1C-11CE-ADE5-00AA0044773D):DB_GetCommercialStorageInfo(dbo.smp_check_purchased_item): Invalid object name 'billing.dbo.PaidItem'.
I've narrowed down the stored procedure and here is the problematic code: dbo.smp_check_purchased_item

Code:
SELECT @OUT_TOTAL_ITEM_COUNT = COUNT(*) from billing.dbo.PaidItem WHERE taken_account_id = @IN_ACCOUNT_ID AND item_code <> 910000 AND rest_item_count > 0  AND valid_time > GETDATE() AND isCancel = 0
SELECT @OUT_NEW_ITEM_COUNT   = COUNT(*) from billing.dbo.PaidItem WHERE taken_account_id = @IN_ACCOUNT_ID AND item_code <> 910000 AND rest_item_count > 0  AND confirmed = 0 AND valid_time > GETDATE() AND isCancel = 0
The problem is every time I login my action bars are empty, I don't have HV and my keybindings are empty as well as a notice that says: "Notice: ?????????????????????????????????????????????????? ?????". There might be other problems but I've not noticed them.

I've fixed it by just changing the values to 1 each. Here is what my dbo.smp_check_purchased_item is:

Code:
USE [Telecaster]
GO
/****** Object:  StoredProcedure [dbo].[smp_check_purchased_item]    Script Date: 6/23/2013 11:07:14 AM ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
-- smp_read_purchased_item_list

-- start of smp_check_purchased_item   캐쉬템 창고에 아이템 있는지 여부 검사
ALTER PROCEDURE [dbo].[smp_check_purchased_item]
@IN_ACCOUNT_ID			INT,
@IN_CHARACTER_ID		INT,
@OUT_TOTAL_ITEM_COUNT	INT		OUTPUT,
@OUT_NEW_ITEM_COUNT		INT		OUTPUT,
@OUT_PREMIUM_TICKET		INT		OUTPUT,
@OUT_PREMIUM_REST_TIME	INT		OUTPUT,
@OUT_STAMINA_REGEN_TIME	INT		OUTPUT

 
AS
SET NOCOUNT ON

SET @OUT_PREMIUM_TICKET  = 0
SET @OUT_PREMIUM_REST_TIME = 0
SET @OUT_STAMINA_REGEN_TIME = 0
SELECT @OUT_PREMIUM_TICKET = 1 --, @OUT_PREMIUM_REST_TIME = DATEDIFF( second, GETDATE(), MAX( GETDATE()+30 ) )
/*SELECT @OUT_PREMIUM_TICKET = COUNT(*), @OUT_PREMIUM_REST_TIME = DATEDIFF( second, GETDATE(), MAX( valid_time ) ) FROM billing.dbo.PaidItem WHERE taken_account_id = @IN_ACCOUNT_ID AND item_code = 910000 AND valid_time > GETDATE() AND isCancel = 0

IF @OUT_PREMIUM_TICKET < 1
BEGIN
	SET @OUT_PREMIUM_REST_TIME = 0

	DECLARE @LOGOUT_TIME		DATETIME
	SET @LOGOUT_TIME = GETDATE()

	SELECT @LOGOUT_TIME = logout_time FROM Character WITH (NOLOCK) WHERE account_id = @IN_ACCOUNT_ID AND sid = @IN_CHARACTER_ID
	SELECT @OUT_STAMINA_REGEN_TIME = DATEDIFF( minute, @LOGOUT_TIME, MAX( valid_time ) ) FROM BILLING.Billing.dbo.PaidItem WHERE taken_account_id = @IN_ACCOUNT_ID AND item_code = 910000 AND valid_time > @LOGOUT_TIME AND isCancel = 0

	IF @OUT_STAMINA_REGEN_TIME < 1 OR @OUT_STAMINA_REGEN_TIME IS NULL
	BEGIN
		SET @OUT_STAMINA_REGEN_TIME = 0
	END

	--DECLARE @NO_LV INT
	--DECLARE @NO_Total_JP INT
	--SELECT @NO_LV = MAX(lv), @NO_Total_JP = MAX(total_jp) from character WITH(NOLOCK) WHERE account_id = @IN_ACCOUNT_ID AND Name not like '@%'

	--IF  @NO_LV < 30 AND @NO_Total_JP < 100000
	--BEGIN
	--SET @OUT_PREMIUM_TICKET  = 1
	--SET @OUT_PREMIUM_REST_TIME = 3600 * 5
	--END
	
END

--IF  @OUT_PREMIUM_REST_TIME < 3600 * 5
--BEGIN
	
	--DECLARE @LV INT
	--DECLARE @Total_JP INT
	--SELECT @LV = MAX(lv), @Total_JP = MAX(total_jp) from character WITH(NOLOCK) WHERE account_id = @IN_ACCOUNT_ID AND Name not like '@%'

	--IF  @LV < 30 AND @Total_JP < 100000
	--BEGIN
	--SET @OUT_PREMIUM_TICKET  = 1
	--SET @OUT_PREMIUM_REST_TIME = 3600 * 5
	--END
--END
*/

SELECT @OUT_TOTAL_ITEM_COUNT = 1
SELECT @OUT_NEW_ITEM_COUNT   = 1

RETURN @@ERROR
It seems to work (also I made it with a no limit HV pass). If there is a better way please let me know, thanks



kiasta is offline  
Thanks
2 Users
Old   #2
 
elite*gold: 0
Join Date: Jun 2013
Posts: 8
Received Thanks: 0
restore billing db
or make it cash usable server 0


Mixmaster1200 is offline  
Reply



« Previous Thread | Next Thread »

Similar Threads
[SQL] Stored Procedure for TitleUpdating Automatic
heya guys, this was made a looooooong time ago when we wanted to make title giving automatic on devias. however, it was never used cuz of...
11 Replies - SRO PServer Guides & Releases
Hello, I have a problem with a stored procedure when you log into the game.
Posts Forum on this thread did not help me! Any thoughts about this problem, screen :handsdown: http://s017.radikal.ru/i437/1208/20/992648841219.jpg
5 Replies - Rappelz Private Server
[BR Files] Missing stored procedure: _ResetQuestByCharName
Anyone have this stored procedure for Black Rogue DB? o.O I keep getting this error in GS and it's really annoying (doesn't affect performance, just...
2 Replies - SRO PServer Ask the Experts
[HELP]Res toon stored Procedure
Hi all, hopefully someone can tell me what i am doing wrong. I am trying to use the dbo.usp_GM_Recovery_Char and it completes without errors...
0 Replies - Shaiya Private Server



All times are GMT +1. The time now is 17:45.


Powered by vBulletin®
Copyright ©2000 - 2017, Jelsoft Enterprises Ltd.
SEO by vBSEO ©2011, Crawlability, Inc.

Support | Contact Us | FAQ | Advertising | Privacy Policy | Abuse
Copyright ©2017 elitepvpers All Rights Reserved.