D
David A. Caballero J.
I have a 3 layer system, SQL Server 2000 database, COM+ dll's (VC++ 6) and
ASP frontend, this system has been in production for quite some time using
english, spanish and portuguese versions. Now I've been asked to test the
system to function with Simplified chinese. The development of the system
was outsourced and we don't have communication with the company (some sort
of legal problems i think).
Now, I've been reviewing the code and recompiled one of the core DLL's for
unicode support with no problems, I've tested the database (SQL Server 2000)
inserting Simplified Chinese characters and the DB supports it fine (the DB
fields are NVARCHAR), in the ASP frontend, the retrievel process (calling
the COM+ DLL functions) works fine displaying this data I inserted directly
in the DB.
However, when I try inserting this data through the ASP frontend I'm getting
errors regarding the length of the strings, I'm testing the data insertion
in a field limited to 100 characters, the data I'm testing are 23 Simplified
Chinese symbols or characters and when I insert them directly in the DB
there is no problem, the DB correctly interprets the string as 23 characters
long, but when I test the length of the same string on the ASP page it says
its 183 characters long, so I'm guessing the ASP code is doing some kind of
implicit conversion, I already tried setting the asp session codepage to
65001 for unicode support with the same outcome. Any ideas or tips?
Sorry for the long post, I would reaaly appreciate any kind of help.
David
ASP frontend, this system has been in production for quite some time using
english, spanish and portuguese versions. Now I've been asked to test the
system to function with Simplified chinese. The development of the system
was outsourced and we don't have communication with the company (some sort
of legal problems i think).
Now, I've been reviewing the code and recompiled one of the core DLL's for
unicode support with no problems, I've tested the database (SQL Server 2000)
inserting Simplified Chinese characters and the DB supports it fine (the DB
fields are NVARCHAR), in the ASP frontend, the retrievel process (calling
the COM+ DLL functions) works fine displaying this data I inserted directly
in the DB.
However, when I try inserting this data through the ASP frontend I'm getting
errors regarding the length of the strings, I'm testing the data insertion
in a field limited to 100 characters, the data I'm testing are 23 Simplified
Chinese symbols or characters and when I insert them directly in the DB
there is no problem, the DB correctly interprets the string as 23 characters
long, but when I test the length of the same string on the ASP page it says
its 183 characters long, so I'm guessing the ASP code is doing some kind of
implicit conversion, I already tried setting the asp session codepage to
65001 for unicode support with the same outcome. Any ideas or tips?
Sorry for the long post, I would reaaly appreciate any kind of help.
David