automatically create table and index for mysql.