Question

When inserting text into a TEXT column in SQL Server using ADO, i get the error:

Code page translations are not supported for the text data type. From: 1257 To: 1252.

Now it is true that i've changed my Windows code page to 1257 (Estonian).

My question is: How does SQL Server know what code page i'm running in?

All strings sent to and from the server are sent as wide (unicode) strings. At the server, SQL Server is then forced to stuff the unicode string into a TEXT (not NTEXT) column. The text column is set to use collation code page 1252.

There are no characters in the source string that are outside of the Windows 1252 code page. Even if there were, how does SQL Server know i'm running code page 1257?

i've tried profiling my connection to SQL Server, and i see nothing that looks like the client identifying its code page with the server.

Was it helpful?

Solution

I hope I'm not correct and this is pre-SP3 SQL Server 2000...

Fixed in SP3, see KB 317956

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top