I need to differentiate between nodes starting with 'O' and nodes starting with 'Ö' (o umlaut).
The problem is that since the node table and the title column have utf8_general_ci collation, MYSQL does not treat o and ö umlaut differently and this query returns nodes starting with O AND nodes starting with Ö
SELECT node.nid AS nid
FROM node AS node
WHERE node.status <> 0
AND SUBSTR( node.title, 1, 1 ) = 'O'
Since all Drupal modules use utf8_general_ci collation, I guess changing the collation of the table and entire database is probably not a good idea.
What is a good workaround for this?