Changed other files for same DB performance loop fix
Added legacy table creation