You are right .. we went OT .. sorry for that 
This guide just caught my attention and made me giggle a bit ... A guide to improve performance, yet the way you do it is far from "performant"
.... nevertheless, very good information and usefull. Keep them coming 
+rep from me.
ps: Instead of opening a table and sorting it (very memory heavy) to get the last id, you could also use: "select max(id) from object_spawns".
Code:
1. select max(id) from Gameobject_spawns;
2. Note the id, add objects in game.
3. Insert into Gameobject_staticspawns select * from Gameobject_spawns where id > "id from step 1";