I have a table called x
with column LegalName
since they are over 10K+, I want to write a query that returns me names that have accents. (á, é, í, ó, ú, ü, ñ). Is there a better way other than actually searching for them using where
? Example of my current SQL query : Select * from x WHERE LegalName LIKE '%é%'
and i have added a lot of 'or' statements. I am bound to miss out something. Any recommendations?
Asked
Active
Viewed 359 times
1

Indigo
- 777
- 2
- 13
- 25
-
1quick/dirty possibility: convert to a charset that doesn't support accents, so theoretically `á` would become a plain `a`, then you do a strict comparison of the deaccented string against the original. if they're different, then you've got accented chars. – Marc B Jul 24 '15 at 18:43
-
1this may help http://stackoverflow.com/questions/401771/how-can-i-find-non-ascii-characters-in-mysql – Vamsi Prabhala Jul 24 '15 at 18:46