MySQL Find non-ascii characters using REGEXP

To find non-ascii characters using a SELECT query, run a query similar to the following:
SELECT
    *
FROM
    `mytable`
WHERE
    `column` REGEXP(CONCAT('[', CHAR(128), '-', CHAR(255), ']'))

1 comment

  1. anonymous

    SELECT * FROM `table` WHERE NOT HEX(`column`) REGEXP '^([0-7][0-9A-F])*$'

Leave a Reply