add more joblevels ...
This is for _Reflevel at the db (shard)
PHP Code:
1 118 1 0 0 24 70875 70875 70875
2 470 1 0 0 47 2388750 2388750 2388750
3 1058 1 0 0 71 8793750 8793750 8793750
4 1880 2 0 0 94 38745000 38745000 38745000
5 2938 2 0 0 118 91665000 91665000 91665000
6 5640 4 0 0 141 240187500 240187500 240187500
7 9048 5 0 0 165 2147483647 2147483647 2147483647
8 13160 6 0 0 188 2147483647 2147483647 2147483647
9 17978 7 0 0 212 2147483647 2147483647 2147483647
10 23500 9 0 0 235 2147483647 2147483647 2147483647
11 34898 12 0 0 259 2147483647 2147483647 2147483647
12 47940 15 0 0 282 2147483647 2147483647 2147483647
13 62628 18 0 0 306 2147483647 2147483647 2147483647
14 78960 21 0 0 329 2147483647 2147483647 2147483647
15 96938 24 0 0 353 2147483647 2147483647 2147483647
16 127840 30 0 0 376 2147483647 2147483647 2147483647
17 161798 35 0 0 400 2147483647 2147483647 2147483647
18 198810 41 0 0 423 2147483647 2147483647 2147483647
19 238878 47 0 0 447 2147483647 2147483647 2147483647
20 282000 53 0 0 470 2147483647 2147483647 2147483647
Code:
Use SRO_VT_SHARD
GO
Create Table _RoyalTrijob
(
CharID int,
Contribution bigint)
aand add this to _addlogchar in the log db...
Code:
if (@EventID=6) -- Royalblade , Extension for Contribution saving
BEGIN
Declare @Contri int =(Select Contribution from SRO_VT_SHARD.dbo._CharTrijob where CharID=@CharID )
IF @CharID in (Select charid from _RoyalTrijob)
begin
Update SRO_VT_SHARD.dbo._RoyalTrijob Set Contribution+=@Contri where Charid=@CharID
Update SRO_VT_SHARD.dbo._CharTrijob Set Contribution =0 where CharID=@CharID
end
else if (@CharID not in (Select charid from _RoyalTrijob))
begin
Insert into SRO_VT_SHARD.dbo._RoyalTrijob (CharID,Contribution) values (@CharID,@Contri)
Update SRO_VT_SHARD.dbo._CharTrijob Set Contribution =0 where CharID=@CharID
end
END
Code:
/****** Object: StoredProcedure [dbo].[_AddLogChar] Script Date: 04/14/2013 14:55:51 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
ALTER procedure [dbo].[_AddLogChar]
@CharID int,
@EventID tinyint,
@Data1 int,
@Data2 int,
@strPos varchar(64),
@Desc varchar(128)
as
declare @len_pos int
declare @len_desc int
set @len_pos = len(@strPos)
set @len_desc = len(@Desc)
if (@EventID=6)
BEGIN
Declare @Contri int =(Select Contribution from SRO_VT_SHARD.dbo._CharTrijob where CharID=@CharID )
IF @CharID in (Select charid from _RoyalTrijob)
begin
Update SRO_VT_SHARD.dbo._RoyalTrijob Set Contribution+=@Contri where Charid=@CharID
Update SRO_VT_SHARD.dbo._CharTrijob Set Contribution =0 where CharID=@CharID
end
else if (@CharID not in (Select charid from _RoyalTrijob))
begin
Insert into SRO_VT_SHARD.dbo._RoyalTrijob (CharID,Contribution) values (@CharID,@Contri)
Update SRO_VT_SHARD.dbo._CharTrijob Set Contribution =0 where CharID=@CharID
end
END
if (@len_pos > 0 and @len_desc > 0)
begin
insert _LogEventChar values(@CharID, GetDate(), @EventID, @Data1, @Data2, @strPos, @Desc)
end
else if (@len_pos > 0 and @len_desc = 0)
begin
insert _LogEventChar (CharID, EventTime, EventID, Data1, Data2, EventPos) values(@CharID, GetDate(), @EventID, @Data1, @Data2, @strPos)
end
else if (@len_pos = 0 and @len_desc > 0)
begin
insert _LogEventChar (CharID, EventTime, EventID, Data1, Data2, strDesc) values(@CharID, GetDate(), @EventID, @Data1, @Data2, @Desc)
end
else
begin
insert _LogEventChar (CharID, EventTime, EventID, Data1, Data2) values(@CharID, GetDate(), @EventID, @Data1, @Data2)
end
In case u want the whole procedure