View Single Post
  #69  
Old 01-31-2004, 10:16 PM
Monrezz's Avatar
Monrezz
Dragon
 
Join Date: Mar 2003
Location: #loc
Posts: 745
Default

How do you redirect the output of the query?

I'm not worried about having a few spawns removed by it, if it means it gets rid of most dupe spawns. If it removed anyone too important I can add them in by hand later. Simply changing to:

SELECT CONCAT('delete from spawn2 WHERE id = ', max(spawn2.id),'; DELETE FROM spawnentry WHERE spawngroupID = ', max(spawn2.spawngroupID),';') Query
FROM spawn2, spawnentry, npc_types
WHERE spawn2.spawngroupID = spawnentry.spawngroupID
AND spawnentry.npcID = npc_types.ID
AND spawn2.pathgrid = 0
GROUP by zone, x, y, z, REPLACE(npc_types.name,'_00','')
HAVING COUNT(spawn2.id) > 1
ORDER BY zone, x, y, z, npc_types.name

...will do it (after sourcing)?

Thanks,

Monrezz
__________________

kRPG Profile
Reply With Quote