mysql 查询某字段内的7位数字
SELECT
*
FROM
`test`.`201611atk-6ne`
WHERE
CAST(
`test`.`201611atk-6ne`.`Tour Code` AS CHAR CHARACTER
SET utf8
) COLLATE utf8_general_ci REGEXP '^[0-9]{7}';
[Err] 2014 - Commands out of sync; you can't run this command now
把REGEXP换成LIKE 也提示2014错误