This is a discussion on Unicode SQL Statements translated according to OS default locale ??? within the MS SQL ODBC forums, part of the Microsoft SQL Server category; --> Hello everybody, My Environment: - W2K with SP3, English default locale and Central Europe language group installed , - ...
| |||||||
| Register | FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read |
| ||||
| Hello everybody, My Environment: - W2K with SP3, English default locale and Central Europe language group installed , - Microsoft SQL Server 2000 SP3 - SQL_Latin1_General_CP1_Cl_AS collation I have a Unicode application connecting to SQL Server through ODBC. I created a database called şuţ (that is U+015F, U+0075, U+0163 something like "sut" with cedilla under "s" and under "t"). When I try to "select name from sysdatabases" I get the correct results. If I try to use a parameterized statement, for example "insert into MyTable (ColName) values (?)" and I bind the parameter to the name specified above, everything is Ok. The problem is that if I try to execute a (prepared or direct) statement without parameters, like "use şuţ exec sp_spaceused", the statement gets translated (I verified with the SQL Profiler) into "use sut exec sp_spaceused" and it fails with error 911 "Could not locate entry in sysdatabases for database ‘sut'. No entry found with that name. Make sure that the name is entered correctly." Again, I compiled my application as Unicode and the statements are Unicode strings, with the correct name How can avoid that translation? Any help would be greatly appreciated Dan |