simplified tablecreation query a little.