Jump to content

nchar/nvarchar datatype cannot be display


matrixtlm

Recommended Posts

Dear all, Having some problem with my DB/ASP page. I'll try to make it brief. Using SQL Server 2000. Developing in ASP. Currently designing a chinese webpage. Do i need to set the datatype to "nchar/nvarchar" to store the chinese character? First, I try setting my datatype to "nchar". I paste a chinese character inside my table. The character can be view (in chinese character) inside EM. However, when I SELECT it and display in browser, it return as "????". In my <META> I try put the charset=UTF-8, still the browser display "????". Second, I try setting datatype to varchar. Paste the chinese character inside my table. EM will stored as "????". SELECT statement will also display "????" in browser.How can I tackle this problem? Thanks in advance.

Link to comment
Share on other sites

  • 2 weeks later...
  • 2 weeks later...
Guest hcleong
Dear all, Having some problem with my DB/ASP page. I'll try to make it brief. Using SQL Server 2000. Developing in ASP. Currently designing a chinese webpage. Do i need to set the datatype to "nchar/nvarchar" to store the chinese character? First, I try setting my datatype to "nchar". I paste a chinese character inside my table. The character can be view (in chinese character) inside EM. However, when I SELECT it and display in browser, it return as "????". In my <META> I try put the charset=UTF-8, still the browser display "????". Second, I try setting datatype to varchar. Paste the chinese character inside my table. EM will stored as "????". SELECT statement will also display "????" in browser.How can I tackle this problem? Thanks in advance.

Try to put this at the beginnign of the code -> Response.CharSet = "utf-8"
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...