View Single Post
  #5  
Old 09-18-2015, 03:54 PM
Kingly_Krab
Administrator
 
Join Date: May 2013
Location: United States
Posts: 1,603
Default

Use this query to see spell ID ranges that are open:
Code:
SELECT (a.id + 1) AS `START`, (MIN(b.id) - 1) AS `END`, ((MIN(b.id - 1)) - (a.id + 1)) AS `AMOUNT` FROM spells_new AS a, spells_new AS b WHERE (a.id < b.id) GROUP BY a.id HAVING (`START` < MIN(b.id)) ORDER BY `AMOUNT` DESC;
Reply With Quote