I’ve got some problems on a .NET site where both Latin (åäö) and Latvian (āē) characters would need to co-exist. In the database, I’m using nvarchar and ntext for my fields, and if I enter the texts directly into the database, everything works fine.
The problem is when I enter the exact same text using a form that does an SQL UPDATE, the Latvian chars get converted to similar Latin chars, so the string “åäöāē” would be saved as “åäöae”.
I’ve tried a bit with different CodePages, but I’m not yet getting the results I want. Does anyone have any suggestions?
Is your SQL statement passing the value in to the db as a unicode value?
e.g. basic example
should be:
Obviously I’d recommend you use parameterised SQL/stored procedure and define the parameter as an NVARCHAR, but you get what I’m saying.