EQEmulator Forums

EQEmulator Forums (https://www.eqemulator.org/forums/index.php)
-   Support::General Support (https://www.eqemulator.org/forums/forumdisplay.php?f=598)
-   -   Mysql Query help (https://www.eqemulator.org/forums/showthread.php?t=26619)

paaco 10-24-2008 04:56 AM

Mysql Query help
 
What would I need to type to take all items with a recommended level over 60 out of loot tables completely. So they don't drop anywhere.

Sorry for the noob question but I can't seem to get it lol ;p

paaco 10-24-2008 03:19 PM

Someone smart has to know ;p

spoon 10-24-2008 04:04 PM

Code:

mysql> DELETE FROM `items` WHERE `reclevel` > 60;
edit: wait do you want JUST the loot tables?

spoon 10-24-2008 04:05 PM

And if you want required:

Code:

mysql> DELETE FROM `items` WHERE `reqlevel` > 60;

spoon 10-24-2008 04:16 PM

If you only want to remove them from the loot tables use:

to see what there are:
Code:

SELECT
        `items`.`id`
FROM
        `lootdrop_entries`
        LEFT JOIN
                `items`
        ON `lootdrop_entries`.`item_id` = `items`.`id`
WHERE
        `items`.`reclevel` > 60;

Code:

SELECT
        `items`.`id`
FROM
        `lootdrop_entries`
        LEFT JOIN
                `items`
        ON `lootdrop_entries`.`item_id` = `items`.`id`
WHERE
        `items`.`reqlevel` > 60;

to delete:

Code:

DELETE
        `lootdrop_entries`
FROM
                `lootdrop_entries`
        LEFT JOIN
                `items`
        ON `lootdrop_entries`.`item_id` = `items`.`id`
WHERE
        `items`.`reclevel` > 60;

and

Code:

DELETE
        `lootdrop_entries`
FROM
                `lootdrop_entries`
        LEFT JOIN
                `items`
        ON `lootdrop_entries`.`item_id` = `items`.`id`
WHERE
        `items`.`reqlevel` > 60;


AndMetal 10-25-2008 12:22 AM

If you wanted to do both at the same time, you should be able to add an OR to the WHERE clause. Same with the SELECT query.

ChaosSlayer 10-25-2008 01:15 AM

recommended level over 60


All times are GMT -4. The time now is 01:33 PM.

Powered by vBulletin®, Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.