View Single Post
  #3  
Old 10-25-2004, 10:33 PM
ajb20
Hill Giant
 
Join Date: Jul 2004
Posts: 106
Default

Code:
select npc_types.id, npc_types.name, spawn2.zone, spawn2.spawngroupid
from npc_types, spawn2, spawnentry
where spawnentry.npcID = npc_types.ID
and spawnentry.spawngroupid = spawn2.spawngroupid;

This way you can see what npcid is part of what npcgroupid and than you do something like:

update spawn2
set respawntime = xx
where spawngroupid = xx
or spwngroupid = xx
or ......;

If you want to be more specific in the select command and just see npcs in one zone:

Code:
select npc_types.id, npc_types.name, spawn2.zone, spawn2.spawngroupid
from npc_types, spawn2, spawnentry
where spawnentry.npcID = npc_types.ID
and spawnentry.spawngroupid = spawn2.spawngroupid
and zone = 'zoneshortname';
Keep in mind you can NOT edit the query in MySQL-front due to the results being from multiple tables.
Reply With Quote