Is there an easy way to replicate the behavior of MySQL's utf_general_ci
collation in C#?
In particular, given a Unicode string, I want to generate a(n ASCII?) string that can then be trivially sorted or compared, as utf_general_ci
would.
I found this question, which shows how to strip accents from strings, which looks like a similar but not quite equivalent function, e.g., it doesn't decompose ß
into ss
.
For my purposes, that may end up being good enough, but if there's a way to replicate its behavior completely I'd prefer that.