#187 Fixed up sql statements and validated spawns