Advantage Database Server 10 error 5211 - There is an error converting Unicode string

I'm converting a D7 app into D2009 and I've faced an issue with the Advantage Database Server (Local). Whenever I include non-parameterized Turkish characters in queries I get the error

[iAnywhere Solutions][Advantage SQL][ASA] 
Error 5211: There is an error converting Unicode string to or from code page string.
Some Unicode characters cannot be converted to code page characters. 

I've tried using ansistrings in the command, like in;

AdsQuery1.SQL.Text:=AnsiString('SELECT something FROM sometable WHERE somefield=''somelocalçharaçterş'' ');

But to no avail. I've also set AdsConnection's AdsCollation values to ANSI, OEM, TURKISH-1254 but the outcome was the same. Any ideas?


Can you take a look of the adscollate.adt that is in the same directory of the adslocal32.dll?

According to the help file, a possible cause of the problem is that an older version of the adscollate.adt is loaded by the server. The 10.0 version of the adscollate.adt has some additional columns, one of them being the "UnicodeLocale".

What is the ANSI/OEM setting in the adslocal.cfg?

What is the result if you run this "SELECT ::stmt.collation FROM system.iota"?

Need Your Help

Elegant way to retry blocks in Smalltalk


Smalltalk supports retry exceptions by using on: retry method defining the behavior between retries. I want to implement retry behaviors consisting of two additional operations: delayInterval,