|
You last visited: Today at 16:54
Advertisement
[Release]QUERY-How To REMOVE a Completly Race Drop Degree
Discussion on [Release]QUERY-How To REMOVE a Completly Race Drop Degree within the SRO PServer Guides & Releases forum part of the SRO Private Server category.
09/22/2014, 14:23
|
#1
|
elite*gold: 86
Join Date: Jan 2012
Posts: 335
Received Thanks: 135
|
[Release]QUERY-How To REMOVE a Completly Race Drop Degree
Hi Elitepvpers.
Im here to day to give you a query that can remove a completely race degree drop.
For Example, Removing a Degree 10 Euro
PHP Code:
USE SRO_VT_SHARD DELETE _RefDropItemAssign FROM _RefDropItemAssign Drops LEFT join _RefObjCommon Objects ON (Drops.RefItemID = Objects.ID) WHERE CodeName128 like '%ITEM_EU_%_10_%'
'_10_' Depends on the Degree,
'_EU_' Depends on the Race,
P.S: Completely*
|
|
|
09/22/2014, 15:00
|
#2
|
elite*gold: 56
Join Date: Oct 2013
Posts: 1,165
Received Thanks: 774
|
Hey, i wrote a slightly nicer query with the same function... i dont like it to use the CodeName for itemtype selection
Code:
DECLARE @Type BIT = 1, --(0 = Equip , 1 = Stones / Tablets)
@Degree TINYINT = 0, --(0 = all degrees),
@Race BIT = 0, --(0 = CH , 1 = EU)
@MinClass TINYINT,
@MaxClass TINYINT
IF @Type = 0
BEGIN
IF @Degree = 0
BEGIN
SELECT @MinClass = MIN(ROI.ItemClass),
@MaxClass = MAX(ROI.ItemClass)
FROM _RefObjItem ROI
INNER JOIN _RefObjCommon ROC
ON ROI.ID = ROC.Link
WHERE ROC.TypeID1 = 3
AND ROC.TypeID2 = 1
END
ELSE
BEGIN
SELECT @MinClass = @Degree * 3 - 2,
@MaxClass = @Degree * 3
END
UPDATE RDI
SET Service = 0
FROM _RefDropItemAssign RDI
INNER JOIN _RefObjCommon ROC
ON RDI.RefItemID = ROC.ID
INNER JOIN _RefObjItem ROI
ON ROC.Link = ROI.ID
WHERE ROC.TypeID1 = 3
AND ROC.TypeID2 = 1
AND ROC.Country = @Race
AND ROI.ItemClass BETWEEN @MinClass AND @MaxClass
END
IF @Type = 1
BEGIN
IF @Degree = 0
BEGIN
SELECT @MinClass = MIN(ROI.ItemClass),
@MaxClass = MAX(ROI.ItemClass)
FROM _RefObjItem ROI
INNER JOIN _RefObjCommon ROC
ON ROI.ID = ROC.Link
WHERE ROC.TypeID1 = 3
AND ROC.TypeID2 = 3
AND ROC.TypeID3 = 11
AND ROC.TypeID4 BETWEEN 1 AND 3
END
ELSE
BEGIN
SELECT @MinClass = @Degree,
@MaxClass = @Degree
END
UPDATE RDI
SET Service = 0
FROM _RefDropItemAssign RDI
INNER JOIN _RefObjCommon ROC
ON RDI.RefItemID = ROC.ID
INNER JOIN _RefObjItem ROI
ON ROC.Link = ROI.ID
WHERE ROC.TypeID1 = 3
AND ROC.TypeID2 = 3
AND ROC.TypeID3 = 11
AND ROC.TypeID4 BETWEEN 1 AND 3
AND ROI.ItemClass BETWEEN @MinClass AND @MaxClass
END
|
|
|
09/22/2014, 15:12
|
#3
|
elite*gold: 86
Join Date: Jan 2012
Posts: 335
Received Thanks: 135
|
Quote:
Originally Posted by Syloxx
Hey, i wrote a slightly nicer query with the same function... i dont like it to use the CodeName from itemtype selection
|
Great job dude. Welldone, But i'd prefer the codename selection for the beginners.
|
|
|
09/22/2014, 15:42
|
#4
|
elite*gold: 0
Join Date: Sep 2009
Posts: 248
Received Thanks: 127
|
You should use an update instance instead of delete.
I mean service = 0
|
|
|
09/22/2014, 23:07
|
#5
|
elite*gold: 50
Join Date: Mar 2013
Posts: 1,153
Received Thanks: 412
|
why so complicated set service 0
PHP Code:
update _RefDropItemAssign SET Service = 0 from _RefDropItemAssign p inner join _RefObjCommon a on a.ID = p.RefItemID where a.CodeName128 like '%ITEM_EU_%_10_%' and p.Service = 0
GS crash? re-back service 1
PHP Code:
update _RefDropItemAssign SET Service = 1 from _RefDropItemAssign p inner join _RefObjCommon a on a.ID = p.RefItemID where a.CodeName128 like '%ITEM_EU_%_10_%' and p.Service = 1
|
|
|
09/23/2014, 12:08
|
#6
|
elite*gold: 56
Join Date: Oct 2013
Posts: 1,165
Received Thanks: 774
|
1st readd wont work
2nd where u can disable CH / EU only
|
|
|
09/25/2014, 00:46
|
#7
|
elite*gold: 86
Join Date: Jan 2012
Posts: 335
Received Thanks: 135
|
Quote:
Originally Posted by Tazdingo7
You should use an update instance instead of delete.
I mean service = 0
|
setting service = 0 causes a gs crash bro
|
|
|
09/25/2014, 00:50
|
#8
|
elite*gold: 85
Join Date: Feb 2014
Posts: 1,055
Received Thanks: 1,643
|
Don't need the "BEGIN" and "END" keywords there. Y U DO DIS?
|
|
|
09/25/2014, 02:14
|
#9
|
elite*gold: 50
Join Date: Mar 2013
Posts: 1,153
Received Thanks: 412
|
Quote:
Originally Posted by Syloxx
1st readd wont work
2nd where u can disable CH / EU only
|
PS: FIXED
|
|
|
09/25/2014, 08:04
|
#10
|
elite*gold: 56
Join Date: Oct 2013
Posts: 1,165
Received Thanks: 774
|
Quote:
Originally Posted by blablaRoyal
Don't need the "BEGIN" and "END" keywords there. Y U DO DIS?
|
true, begin / end is useless if there is only one subquery but its visually appealing and i just ask me why u didn't said:
-SELECT @MinClass and @MaxClass can be done with 1 selection
-IF @Degree = 0 ALL items will be disabled even pots because no TypeID set
anyway here is a fix for the Degree = 0 problem:
Code:
DECLARE @Type BIT = 1, --(0 = Equip , 1 = Stones / Tablets)
@Degree TINYINT = 0, --(0 = all degrees),
@Race BIT = 0, --(0 = CH , 1 = EU)
@MinClass TINYINT,
@MaxClass TINYINT
IF @Type = 0
BEGIN
IF @Degree = 0
BEGIN
SELECT @MinClass = MIN(ROI.ItemClass),
@MaxClass = MAX(ROI.ItemClass)
FROM _RefObjItem ROI
INNER JOIN _RefObjCommon ROC
ON ROI.ID = ROC.Link
WHERE ROC.TypeID1 = 3
AND ROC.TypeID2 = 1
END
ELSE
BEGIN
SELECT @MinClass = @Degree * 3 - 2,
@MaxClass = @Degree * 3
END
UPDATE RDI
SET Service = 0
FROM _RefDropItemAssign RDI
INNER JOIN _RefObjCommon ROC
ON RDI.RefItemID = ROC.ID
INNER JOIN _RefObjItem ROI
ON ROC.Link = ROI.ID
WHERE ROC.TypeID1 = 3
AND ROC.TypeID2 = 1
AND ROC.Country = @Race
AND ROI.ItemClass BETWEEN @MinClass AND @MaxClass
END
IF @Type = 1
BEGIN
IF @Degree = 0
BEGIN
SELECT @MinClass = MIN(ROI.ItemClass),
@MaxClass = MAX(ROI.ItemClass)
FROM _RefObjItem ROI
INNER JOIN _RefObjCommon ROC
ON ROI.ID = ROC.Link
WHERE ROC.TypeID1 = 3
AND ROC.TypeID2 = 3
AND ROC.TypeID3 = 11
AND ROC.TypeID4 BETWEEN 1 AND 3
END
ELSE
BEGIN
SELECT @MinClass = @Degree,
@MaxClass = @Degree
END
UPDATE RDI
SET Service = 0
FROM _RefDropItemAssign RDI
INNER JOIN _RefObjCommon ROC
ON RDI.RefItemID = ROC.ID
INNER JOIN _RefObjItem ROI
ON ROC.Link = ROI.ID
WHERE ROC.TypeID1 = 3
AND ROC.TypeID2 = 3
AND ROC.TypeID3 = 11
AND ROC.TypeID4 BETWEEN 1 AND 3
AND ROI.ItemClass BETWEEN @MinClass AND @MaxClass
END
|
|
|
10/12/2016, 11:53
|
#11
|
elite*gold: 290
Join Date: Oct 2013
Posts: 266
Received Thanks: 191
|
Never works, when I remove or set Services = 0 for D9, D10, D12 then GS crashed
|
|
|
 |
Similar Threads
|
[Release] Query To Drop D13
03/25/2019 - SRO PServer Guides & Releases - 9 Replies
Welcome All
I Know Its Very Old And 90 % Do It But Begnnier Still Can't Do It !
So Today I Will Share This To Help Begnniers
Lets Start
First Query
UPDATE . set ProbGroup34='14.999' where MonLevel='121'
UPDATE . set ProbGroup35='14.999' where MonLevel='121'
UPDATE . set ProbGroup36='14.999' where MonLevel='121'
UPDATE . set ProbGroup34='14.999' where MonLevel='122'
|
[Release]-[Query] Remove Monsters drops (For beginners)
01/22/2017 - SRO PServer Guides & Releases - 15 Replies
Query
USE SRO_VT_SHARD DELETE FROM _RefMonster_AssignedItemDrop where RefitemID like (Select ID From dbo._RefObjCommon Where CodeName128 like 'THE ITEM CODE')
|
[Query]Disable Drop Tablets, And Add Drop Stones
10/27/2016 - SRO PServer Guides & Releases - 10 Replies
This query disable all tablet from mobs:
Update _RefDropItemAssign
set service = 0
where RefItemID between 6295 and 6678
and add stones to drop:
|
[HELP]Need Query or Tutorial on How to Remove Candle event on Revo DB
11/03/2011 - EO PServer Hosting - 1 Replies
Need Query or Tutorial on How to Remove Candle event on Revo :mofo::mofo::mofo::mofo::mofo::mofo:
http://img411.imageshack.us/img411/6105/lulzbanne r.gif
|
Remove the NPC from the Race map
12/08/2010 - EO PServer Hosting - 4 Replies
I need to know how to remove the NPC's from The Race Map I have went on Cq_NPC and Remvoed every NPC that had the mads ID on it
i even unticked the box so i can see 3000
or w/e
and i remvoed all of them but there is 1 NPC blocking it still and his name is Bandit
but my NPC isnt fuly Trasilated so i dont know how i can fix this any ideas
or ever a Trasilation for bandit
|
All times are GMT +1. The time now is 16:54.
|
|