Jump to content
  • 0
louigui0224

(Fixed)Changing all refine of items of all accounts in phpmyadmin.

Question

8 answers to this question

Recommended Posts

  • 0
UPDATE inventory 
INNER JOIN item_db_re ON inventory.nameid = item_db_re.id
SET inventory.refine={CHANGE THIS VALUE TO DESIRED REFINE}
WHERE item_db_re.type IN ({PUT ALL ITEM TYPES SEPARATED BY COMMAS});

https://github.com/rathena/rathena/wiki/Custom_Items

refer to the link on item types.

this method will only work if the person who owns the item is offline.

Edited by Ninja
  • Upvote 1
Link to comment
Share on other sites

  • 0

so for example since the armor is type 4 i should put

UPDATE inventory 
INNER JOIN item_db_re ON inventory.nameid = item_db_re.id
SET inventory.refine=0
WHERE item_db_re.type IN ({4);

 

is this correct??

 

by the way im using pre-re...should i use item_db_pre??? @Ninja

Link to comment
Share on other sites

  • 0

I'd like to suggest to do these database updates when the server is offline. Don't forget to make a backup before you apply your changes. And test them on a local copy.

You can write all your UPDATE-Statements in a sql-file like refineupdate.sql and apply them at once with the command mysql -u user -p database < refineupdate.sql

And yes you can also use the item_db_pre. Don't forget there are multiple tables for items: storage, cart_inventory, inventory, etc.

Link to comment
Share on other sites

  • 0

so before changing eerything.

UPDATE inventory 
INNER JOIN item_db_re ON inventory.nameid = item_db_re.id(So just change item_db_re to item_db_pre?) and everything is ok beside from changing the cartinventory and storage?
SET inventory.refine=0
WHERE item_db_re.type IN ({4);
Link to comment
Share on other sites

  • 0

This is what i put...and it says 0 row affected...and when i tried to search there are still +20 items in the inventory...and when i logged ingame the items still hase refines.

UPDATE inventory 
INNER JOIN item_db ON inventory.nameid = item_db.id
SET inventory.refine=0
WHERE item_db.type IN (256,32,2,1,64,16,512);

 

Bump.

 

already done i type just a very simple code..

UPDATE inventory 
SET inventory.refine=0



UPDATE cart_inventory 
SET cart_inventory.refine=0

UPDATE storage
SET storage.refine=0

 

Edited by louigui0224
Link to comment
Share on other sites

  • -1

He means that you will be using item_db_pre instead of item_db_re and that you have to think about how to modify the sql command that I gave you to also update item refines which are located in other tables such as storage, cart_inventory, etc. :)

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Answer this question...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.



×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use and Privacy Policy.