MySQL – Select where field contents are in UPPERCASE

How to select rows from a table where a field contents are all in UPPERCASE

SELECT
    fieldName
FROM
   tableName
WHERE
   fieldName REGEXP BINARY ‘^[A-Z]+$’

RMTWeb

www.rmtweb.co.uk

RMTWeb - blogging, solving complex technical problems and queries, putting the world to rights and general musings since 1991. Now using a 4G connection that is 5,547 times faster than when writing my first post using a 14.4Kbit modem!

Leave a Reply