fix ddl and query for mysql5.5