Daniel wrote:
how does ado.net SqlDataReader.GetString() know which encoding to read the
data into a string as? Does sql sever set this at the column data type
level, server wide encoding setting, os encoding?
If it is an NVARCHAR you should not have a problem since that is Unicode
like .NET strings.
For a VARCHAR it is much more "fun". I really don't know how
it is done. But if I were to guess based on my small knowledge about
TDS, then I would say that the client tell the server what
charset it is using and the server then delivers the bytes
in the matching charset.
Arne