create tables according to new structure