Register for your free account! | Forgot your password?

You last visited: Today at 20:56

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

Advertisement



[RELEASE] _Items / _ItemPool Clean Query

Discussion on [RELEASE] _Items / _ItemPool Clean Query within the SRO PServer Guides & Releases forum part of the SRO Private Server category.

Reply
 
Old   #1
 
Syloxx's Avatar
 
elite*gold: 56
Join Date: Oct 2013
Posts: 1,165
Received Thanks: 774
[RELEASE] _Items / _ItemPool Clean Query

Hello,

since alot of you guys probably have deleted items by setting ItemID = 0 and forgot totally about the _ItemPool table I`ve coded a little query that is able to detect items that dont exists in any inventory and marks them as "not used" for the Database to overwrite them.

Code:
UPDATE P
SET InUse = 0
FROM _Items I
         JOIN _ItemPool P ON I.ID64 = P.ItemID
         FULL JOIN _Inventory INV ON I.ID64 = INV.ItemID
         FULL JOIN _InvCOS INV_C ON I.ID64 = INV_C.ItemID
         FULL JOIN _Chest C ON I.ID64 = C.ItemID
         FULL JOIN _GuildChest GC ON I.ID64 = GC.ItemID
         FULL JOIN _InventoryForAvatar IFA ON I.ID64 = IFA.ItemID
WHERE P.InUse = 1
  AND INV.ItemID IS NULL
  AND INV_C.ItemID IS NULL
  AND C.ItemID IS NULL
  AND GC.ItemID IS NULL
  AND IFA.ItemID IS NULL
Syloxx is offline  
Thanks
15 Users
Reply


Similar Threads Similar Threads
how to delete from _Items table
11/26/2017 - SRO Private Server - 1 Replies
i have a server that has been opened since years and now my table _Items -which there are huge operations on it- is kinda full so when any operation is executing the table will take little long time to do it any solution to delete "lines" from it to prevent this completion ?
[Release][Query] List All _Items and who they belong too
01/02/2016 - SRO PServer Guides & Releases - 1 Replies
Ok... this query is fun... its not really useful in any systems because its not made for performance... but it will give you a list of every _Item in your database.... and it will tell you who it belongs too... this query works on char invo, avatar invo, pet invo, chest storage and guild storage.... I dont think there is anywhere else to store items,... except for open market... but we wont go there... the query... USE
[Release][Query] Query _InvCOS Items WITH _Char Connection
12/29/2015 - SRO PServer Guides & Releases - 1 Replies
Ok, so i needed to write this query for a procedure im working on and not many people know how to connect the pet inventory table to the character table.... so this query will explain how its done... im not going to explain every single detail, like how there is no charcos when pet is despawned / dead... but yea you can probably figure that all out from this query... The code... USE SELECT pet_invo. ,pet_invo. PetSlot
[Suche]Query für "Alteklinge, Reichsklinge" &' Stichdolche NUR QUERY!
08/18/2010 - Metin2 Private Server - 1 Replies
Ich weiß ich werd nervig aber ich suche die Query's für Alteklinge, Reichsklinge &' Strichdolche Why? Naya, weil ich in der DB i-wie nur Drachenmaulglocke hab ... not more -.- Auf jeden Fall Icon's etc. etc. etc. hab ich ich brauche nur die Query's



All times are GMT +1. The time now is 20:57.


Powered by vBulletin®
Copyright ©2000 - 2026, Jelsoft Enterprises Ltd.
SEO by vBSEO ©2011, Crawlability, Inc.
This site is protected by reCAPTCHA and the Google Privacy Policy and Terms of Service apply.

Support | Contact Us | FAQ | Advertising | Privacy Policy | Terms of Service | Abuse
Copyright ©2026 elitepvpers All Rights Reserved.