select * from num where length(newnum) = 15 //指定字符串长度select * from num where newnum not REGEXP ‘[0-9]{18}|[0-9]{17}X|[0-9]{15}‘//使用正则update num set newnum = upper(newnum) where newnum like ‘%x‘ //将字母大写