searching chat table

09/21/2014 14:11 beetols#1
I'm searching the sql tables for the chat log from the game.
I'm using a ep 4 DB and the original don't work;
i'm running a sql 2008 so i can't open files from newest sql.

Actualy i get this error in the PS_GAMELOG:
Quote:
Could not find stored procedure 'usp_Insert_Chat_Log_E'.

thanks in advanced if anyone can help me about.
09/21/2014 14:25 SnickQ#2
Code:
USE [PS_Chatlog]
GO
/****** Object:  StoredProcedure [dbo].[usp_Insert_Chat_Log_E]    Script Date: 2014-09-21 14:23:59 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO

/****** Object:  Stored Procedure dbo.usp_Insert_Chat_Log_E    Script Date: 2008-6-7 18:30:55 ******/
ALTER     Proc [dbo].[usp_Insert_Chat_Log_E]

/* 
Created by humanws, 2005-10-14
채팅 로그 남기기
 */

@UserUID int,
@CharID int,
@ChatType tinyint,		-- 일반1, 귓말2, 길드3, 파티4, 거래5
@TargetName varchar(30),
@ChatData varchar(128),
@MapID smallint,
@ChatTime datetime

AS

DECLARE @Sql nvarchar(4000)
DECLARE @yyyy varchar(4)
DECLARE @mm varchar(2)
DECLARE @dd varchar(2)

SET @yyyy = DATEPART(yyyy, @ChatTime)
SET @mm = DATEPART(mm, @ChatTime)
SET @dd = DATEPART(dd, @ChatTime)


IF( LEN(@mm) = 1 )
BEGIN
	SET @mm = '0' + @mm
END

IF( LEN(@dd) = 1 )
BEGIN
	SET @dd = '0' + @dd
END

SET @Sql = N'
INSERT INTO PS_ChatLog.dbo.ChatLog
(UserUID, CharID, ChatType, TargetName, ChatData, MapID, ChatTime)
VALUES(@UserUID, @CharID, @ChatType, @TargetName, @ChatData, @MapID, @ChatTime)'

EXEC sp_executesql @Sql, 
N'@UserUID int, @CharID int, @ChatType tinyint, @TargetName varchar(30), @ChatData varchar(128),@MapID smallint, @ChatTime datetime',
@UserUID, @CharID, @ChatType, @TargetName, @ChatData, @MapID, @ChatTime
09/21/2014 15:45 beetols#3
its the same one that i have (i tried to copy), but don't work, continue to give me this error:
Quote:
2014-09-20 17:37:07 err=-1, [Microsoft][ODBC SQL Server Driver][SQL Server]

Could not find stored procedure 'usp_Insert_Chat_Log_E'., SQL STATE: 42000, NATIVE ERROR: 2812 (0xAFC)2014-09-20 17:37:07 DBWrite::LogChat: err=-1, query=EXEC usp_Insert_Chat_Log_E userUID,CharID,4,NULL,'Chat Text',0,'2014-09-20 17:37:07'
2014-09-20 17:37:07 err=-1, [Microsoft][ODBC SQL Server Driver][SQL Server]Could not find stored procedure 'usp_Insert_Chat_Log_E'., SQL STATE: 42000, NATIVE ERROR: 2812
(0xAFC)
my idea was to try to completely replace the PS_ChatLog, but i don't want to download every database that i found for test it.
09/21/2014 15:52 nubness#4
Do you have the PS_ChatLog.dbo.ChatLog table ?
09/21/2014 16:48 beetols#5
solved, thanks nubness

The issue is in the table that have wrong DataType, checking the 'usp_Insert_Chat_Log_E' you can see the right values and edit them by ChatLog (rightclick) design.

if anyone find it helpful thanks Nubness above!!