Jump to content

Question

Posted

Hello. I',m trying to remove all droplist from monsters, and i wanna to leave only Adena.

I tried like that -

DELETE FROM droplist WHERE itemid IN (SELECT item_id FROM etcitem WHERE itemid <> 57);

But not working for me. Maybe anyone can me explain how to make it?

Recommended Posts

  • 1
Posted (edited)
5 minutes ago, Downwade said:

For me not working, or i'm doing something wrong..

uLXaOYb.png

Β 

Select your database, Click on the icon:

capture.PNG.a451e7489cf2bf3df53394d00d73d8a9.PNG

Β 

then press 'New Query' tool,

make sure the new tab of the query will have your database name after the @ like this

Capture2.PNG.0f739122178d1dcc6a61d77c2fc938cd.PNG

(sys is my db)

Β 

run the command by clicking Run tool , be happy

Edited by melron
  • Like 1
  • 0
Posted
1 hour ago, HyperBlown said:

This should be your command.


DELETE FROM droplist WHERE NOT itemId = 57

delete from droplist what? there's no point-out what exactly to delete, just condition :?

  • 0
Posted (edited)
27 minutes ago, Dubxsion said:

delete from droplist what? there's no point-out what exactly to delete, just condition :?

This is correct since DELETE FROM droplist , will delete everything. I prefer to use DELETE FROM droplist WHERE itemId <> 57Β 

( Delete everything from droplist except rows who their itemId field is not equal to 57)

Edited by melron
  • 0
Posted
4 hours ago, Downwade said:

Hello. I',m trying to remove all droplist from monsters, and i wanna to leave only Adena.

I tried like that -


DELETE FROM droplist WHERE itemid IN (SELECT item_id FROM etcitem WHERE itemid <> 57);

But not working for me. Maybe anyone can me explain how to make it?

I can give u another "grandma" noob method to do ur job.

1: Dump ur droplist sql table on ur desktop

2: Make a separate copy of it.

3: Open it with Notepad++

4: Open Find menu (CTRL+F)

5: Navigate to "Mark" tab

6: Type '57' in the search field and check Bookmark line square

7: Press "Mark all" and u will see little dots appearing on the left side of all records containing the id '57'

8: Close search/find menu and navigate to Search tab in notepad++

9: Go to Bookmark tab from the falling menu

10: Click "Inverse Bookmark"

11: Then go again to Bookmark and press "Remove bookmarked lines"

12: This will delete all the records beside the ones that have the id 57

13: Then save the SQL, empty the "droplist" table u already have in ur navicat and execute the SQL u just modified.

14: All records with only Adena inΒ  them will be set in the droplist and u have the thing u wanted.

Hope that helped.

Β 

Its not important how u made it, its important that u managed to do it!

  • 0
Posted (edited)
38 minutes ago, Dubxsion said:

delete from droplist what? there's no point-out what exactly to delete, just condition :?

this will delete all rows that dont have 57 as ItemId... Just execute this inside your database query, and it will work. Well, Ofc I tested first before posting and it worked.

Edited by HyperBlown
  • 0
Posted
1 minute ago, HyperBlown said:

this will delete all rows that dont have 57 as ItemId... Just execute this inside your database query, and it will work. Well, Ofc I tested first before posting and it worked.

i did, it was successful but nothing was deleted, anyway i did it my method with notepad++

  • 0
Posted
1 minute ago, Dubxsion said:

i did, it was successful but nothing was deleted, anyway i did it my method with notepad++

Well, it worked for me. Otherwise I wouldnt post... Did you do on the right database? Did you clicked "refresh" to see if updated? If the command executed without any errors, all rows that doesnt have 57 as itemId should go away. perhaps your droplist is named differently? or the colums are differently named?

  • 0
Posted
3 hours ago, HyperBlown said:

This should be your command.


DELETE FROM droplist WHERE NOT itemId = 57 ο»Ώ

not working your command.

  • 0
Posted
1 hour ago, melron said:

Β I prefer to use DELETE FROM droplist WHERE itemId <> 57Β 

( Delete everything from droplist except rows who their itemId field is not equal to 57)

Β 

  • 0
Posted
9 minutes ago, Downwade said:

not working your command.

Β 

try

Β 

DELETE FROM droplist WHERE NOT (itemid = 57)

Β 

or

Β 

DELETE FROM droplist WHERE itemid NOT IN (57)

Β 

but what @melronΒ said with the <> is the simplest and easiest way to negate the condition

  • 0
Posted
3 minutes ago, sepultribe said:

Β 

try

Β 

DELETE FROM droplist WHERE NOT (itemid = 57)

Β 

or

Β 


DELETE FROM droplist WHERE itemid NOT IN (57)

and this 2 not working.

  • 0
Posted (edited)

if it's not working you don't have any rows that have a column named itemid with values not equal to 57 in your droplist table.

Β 

post your table definition here (command follows)

Β 

describe [db_name.]table_name; //[] mean optional
Edited by sepultribe
  • 0
Posted
1 hour ago, sepultribe said:

if it's not working you don't have any rows that have a column named itemid with values not equal to 57 in your droplist table.

Β 

post your table definition here (command follows)

Β 


describe [db_name.]table_name; //[] mean optional

http://www.mediafire.com/file/2ylu7mujl0al39n/droplist.sql/file

This is my droplist.sql

  • 0
Posted
1 hour ago, Downwade said:

Do you know how to execute commands?

Β 

You are saying is not working. Post your error then lol

I just downloaded your droplist and the command is working excellent..

Β 

Message:

[SQL]DELETE FROM droplist WHERE itemId <> 57

Affected rows: 25607
Time: 0.107s

Β 

  • 0
Posted

Executing command without selected db, perhaps.Β :D

Β 

You have rdy working query, everything is in your hands.Β 

Guest
This topic is now closed to further replies.


  • Posts

    • The Time Has Come!Β  Β  Tomorrow, L2DoubleDamage officially launches! Get ready for epic PvP battles, legendary rewards, and tons of action-packed features! Β  Β Opening Date: February 28, 2025 Β Opening Time by Country: Β Greece: 20:00 Β Brazil: 15:00 Β Russia (Moscow): 21:00 Β Argentina: 15:00 Β Important Note: The donation weapons, armors, and jewelry will be closed for 2 days for the donors. Β  Key Features: Β 100% PvP Full Balance – No Pay to Win! Β Ultra Stable – No Wipes, Long-Term Project! Β Siege Castles: Giran, Aden, Rune Β Giran Siege Reward: 100€ Real Money! (Every week after: 50€) Β VIP Autofarm: x2 Drop & Name Color Change Β 6 Grand Bosses & 6 Special Grand Bosses! Β Casino – Try Your Luck & Win Big! Β Daily PvP Events – Show off your skills! Β Enchant Rates: Safe +6, Max +25 Β JOIN NOW and prepare for the ultimate PvP experience! Check out the official links below: Β  Β Website: L2DoubleDamage Β Discord: Join Here Β Instagram: Follow Us Β YouTube: Watch the Trailer Β Facebook: Like Our Page Β Get ready! The adventure begins tomorrow!Β  Β  πŸš€ JOIN NOW & Experience the Best PvP Gameplay Ever! πŸš€ 🌐 Website: http://www.l2doubledamage.com/ πŸ’¬ Discord: https://discord.gg/l2doubledamage πŸ“· Instagram: https://www.instagram.com/l2doubledamage/ πŸ“˜ Facebook: https://www.facebook.com/profile.php?id=61573159438765&sk=about_contact_and_basic_info πŸ“Ί YouTube: Β 
    • πŸ”₯ L2Custom.com - FRESH START/WIPE! πŸ”₯ πŸ—“οΈ Wipe/Open Date: 2025-03-01, 18:00 GMT+2 βš”οΈ Chronicle: Interlude | Rates: High 🌟 Key Features: βœ… Custom Items – Enhanced PvP Experience βœ… Full Buffer – No Hassle, Just Action βœ… Olympiad (A-Grade Only) – Every Week βœ… Castle Sieges – Every Week πŸš€ Fresh Start – Dominate from Day 1! Gather your clan, forge alliances, and prove your strength on the battlefield! 🌐 Join Now: www.l2custom.com πŸ’₯ Don’t miss out on the ultimate PvP experience! πŸ’₯
    • A new template is available:Β Ancient-World - Responsive HTML Template Β  Β 
    • We are still taking new orders! Let us talk on Telegram!
    • Hello. Looking for bot for L2 Reborn x1 Origin. Some1? L2adrenaline dont work ;/
  • Topics

Γ—
Γ—
  • Create New...