Re: Chinese character display problem
From: User (User_at_aol.com)
Date: 12/18/04
- Next message: Dan Guzman: "Re: Permissions Questions"
- Previous message: SLP: "Re: Copy image BLOB from one table to another"
- In reply to: David Gugick: "Re: Chinese character display problem"
- Messages sorted by: [ date ] [ thread ]
Date: Fri, 17 Dec 2004 16:23:55 -0800
SQL nvarchar can indeed store unicode data.
However the encoding used is UCS-2, like Windows NT/2K - two bytes per char.
ASP and browsers like UTF-8, from 1 to 3 bytes per char.
Try putting the directive <@ CodePage=65001 %> at the top of your ASP page.
This instructs IIS to convert strings from UCS-2 to UTF-8.
You may also want to put in the header:
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
Of course you must also have Chinese font installed.
"David Gugick" <davidg-nospam@imceda.com> wrote in message
news:#p#7qV$4EHA.3828@TK2MSFTNGP09.phx.gbl...
> manisha_css wrote:
> > I am storing some field in chinese. (field type is nvarchar). When i
> > store it i can not see as chinese character but as some sort of
> > unicode characters. (unreadable)
> >
> > When i try to pick it up from database and display in asp page - i
> > get it but same unicode format (unreadabel)
> >
> > Now whether i need to change any database settings (instead of
> > nvarchar use something else ?) OR do i need to install any font ? OR
> > change browser setting ?
> >
> > What's wrong ?
> >
> > regards
> > Manisha
>
> You are using a unicode character column, so I don't think SQL Server is
> the problem. You are either storing incorrect characters or do not have
> your display set to display Chinese. Check the View | Encoding | More
> menu section in IE if that's what you are using. Also, you should be
> able to use HTML to tell IE the page is going to diaply the language you
> need.
>
> --
> David Gugick
> Imceda Software
> www.imceda.com
>
- Next message: Dan Guzman: "Re: Permissions Questions"
- Previous message: SLP: "Re: Copy image BLOB from one table to another"
- In reply to: David Gugick: "Re: Chinese character display problem"
- Messages sorted by: [ date ] [ thread ]
Relevant Pages
|