Sybase NNTP forums - End Of Life (EOL)

The NNTP forums from Sybase - forums.sybase.com - are now closed.

All new questions should be directed to the appropriate forum at the SAP Community Network (SCN).

Individual products have links to the respective forums on SCN, or you can go to SCN and search for your product in the search box (upper right corner) to find your specific developer center.

how can i retrive Chinese character correctly using jConnect 3.0 in Applet

8 posts in JConnect version 3.0 Last posting was on 1998-10-22 03:12:18.0Z
HuangXuejun Posted on 1998-10-13 10:05:52.0Z
Message-ID: <362325FF.21BAB6E1@yahoo.com>
Date: Tue, 13 Oct 1998 18:05:52 +0800
From: HuangXuejun <hxjun@yahoo.com>
X-Mailer: Mozilla 4.04 [en] (WinNT; I)
MIME-Version: 1.0
Subject: how can i retrive Chinese character correctly using jConnect 3.0 in Applet
Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: 7bit
Newsgroups: sybase.public.jconnect30
Lines: 10
Path: forums-1-dub!forums-master.sybase.com!forums.powersoft.com
Xref: forums-1-dub sybase.public.jconnect30:381
Article PK: 255783

i write a java application using jConnect 3.0 , it can retrieve Chinese
character correctly
from ASE 11.5 , but , when i turned the application to Applet , i can
not work properly , the result in English is all ok , but result in
Chinese may be ????? or other strange code .
(i had set the charset to 'eucgb' and versionstring to '3')
thank you !


Lance Andersen Posted on 1998-10-16 12:03:35.0Z
Message-ID: <36273617.A6ECA410@sybase.com>
Date: Fri, 16 Oct 1998 08:03:35 -0400
From: Lance Andersen <lancea@sybase.com>
X-Mailer: Mozilla 4.05 [en] (X11; I; SunOS 5.5.1 sun4m)
MIME-Version: 1.0
Subject: Re: how can i retrive Chinese character correctly using jConnect 3.0 in Applet
References: <362325FF.21BAB6E1@yahoo.com>
Content-Type: multipart/mixed; boundary="------------93B150ED47C470A5690192A6"
Newsgroups: sybase.public.jconnect30
Lines: 49
Path: forums-1-dub!forums-master.sybase.com!forums.powersoft.com
Xref: forums-1-dub sybase.public.jconnect30:379
Article PK: 254625


HuangXuejun wrote:
>
> i write a java application using jConnect 3.0 , it can retrieve Chinese
> character correctly
> from ASE 11.5 , but , when i turned the application to Applet , i can
> not work properly , the result in English is all ok , but result in
> Chinese may be ????? or other strange code .
> (i had set the charset to 'eucgb' and versionstring to '3')
> thank you !

If it works in your standalone java program, then it should work in an
applet. Is your locale set properly for your browser? Have you tried a
different browser?

-lance
team sybase
--
===============================================================================
Lance J. Andersen Email: lancea@sybase.com
Sybase Product Support Engineering Phone:(781) 564-6336
77 South Bedford Street Fax: (781) 564-6148
Burlington, MA 01803

The Dark Knight Returns!!! Let's Go Penguins!!!
===============================================================================


Download VCard vcard.vcf


gonghua Posted on 1998-10-21 04:34:51.0Z
Message-ID: <362D646B.558FF708@online.sh.cn>
Date: Wed, 21 Oct 1998 12:34:51 +0800
From: gonghua <gonghua@online.sh.cn>
X-Mailer: Mozilla 4.07 [en] (WinNT; I)
MIME-Version: 1.0
To: HuangXuejun <hxjun@yahoo.com>
Subject: Re: how can i retrive Chinese character correctly using jConnect 3.0 in Applet
References: <362325FF.21BAB6E1@yahoo.com>
Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: 7bit
Newsgroups: sybase.public.jconnect30
Lines: 18
Path: forums-1-dub!forums-master.sybase.com!forums.powersoft.com
Xref: forums-1-dub sybase.public.jconnect30:375
Article PK: 255774

Hi :
Try to use nchar or nvarchar type in the database.
and you can use the charset eucgb and use the version 2,
because if you use version 3, it will ingore the charset variable
and
use the database default charset .
good luck!

HuangXuejun wrote:

> i write a java application using jConnect 3.0 , it can retrieve Chinese
> character correctly
> from ASE 11.5 , but , when i turned the application to Applet , i can
> not work properly , the result in English is all ok , but result in
> Chinese may be ????? or other strange code .
> (i had set the charset to 'eucgb' and versionstring to '3')
> thank you !


HuangXuejun Posted on 1998-10-21 09:19:59.0Z
Message-ID: <362DA73F.3A5A773C@yahoo.com>
Date: Wed, 21 Oct 1998 17:19:59 +0800
From: HuangXuejun <hxjun@yahoo.com>
X-Mailer: Mozilla 4.07 [en] (WinNT; I)
MIME-Version: 1.0
Subject: Re: how can i retrive Chinese character correctly using jConnect 3.0 in Applet
References: <362325FF.21BAB6E1@yahoo.com> <362D646B.558FF708@online.sh.cn>
Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: 7bit
Newsgroups: sybase.public.jconnect30
Lines: 17
Path: forums-1-dub!forums-master.sybase.com!forums.powersoft.com
Xref: forums-1-dub sybase.public.jconnect30:374
Article PK: 255771

thank you very much , the problem of retrive is resolved ,
but , i can not insert chinese character into database ,
it always raise the error JZ0I6 , i can insert the character
which i retrive from database into database , but i can not
insert the chinese character i type in the text field into database.
why and how ?

gonghua wrote:

> Hi :
> Try to use nchar or nvarchar type in the database.
> and you can use the charset eucgb and use the version 2,
> because if you use version 3, it will ingore the charset variable
> and
> use the database default charset .
> good luck!


gonghua Posted on 1998-10-22 00:52:26.0Z
Message-ID: <362E81CA.27AC753B@online.sh.cn>
Date: Thu, 22 Oct 1998 08:52:26 +0800
From: gonghua <gonghua@online.sh.cn>
X-Mailer: Mozilla 4.07 [en] (WinNT; I)
MIME-Version: 1.0
To: HuangXuejun <hxjun@yahoo.com>
Subject: Re: how can i retrive Chinese character correctly using jConnect 3.0 in Applet
References: <362325FF.21BAB6E1@yahoo.com> <362D646B.558FF708@online.sh.cn> <362DA73F.3A5A773C@yahoo.com>
Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: 7bit
Newsgroups: sybase.public.jconnect30
Lines: 27
Path: forums-1-dub!forums-master.sybase.com!forums.powersoft.com
Xref: forums-1-dub sybase.public.jconnect30:371
Article PK: 255770

Hi:
Try use Isqlapp command in the jconnect first

java Isplapp -Uusername -Ppassword -S jdbc:sybase:Tds:machine:port -C eucgb

and insert chinese in the command line
by the way ,some platform such as English Version 95 or NT with Cstar
perhaps cause
problem! change it to the chinese version 95 or NT

gonghua

HuangXuejun wrote:

> thank you very much , the problem of retrive is resolved ,
> but , i can not insert chinese character into database ,
> it always raise the error JZ0I6 , i can insert the character
> which i retrive from database into database , but i can not
> insert the chinese character i type in the text field into database.
> why and how ?
>
> gonghua wrote:
>
> > Hi :
> > Try to use nchar or nvarchar type in the database.
> > and you can use the charset eucgb and use the version 2,
> > because if you use version 3, it will ingore the charset variable
> > and
> > use the database default charset .
> > good luck!


HuangXuejun Posted on 1998-10-22 03:12:18.0Z
Message-ID: <362EA292.6010D07@yahoo.com>
Date: Thu, 22 Oct 1998 11:12:18 +0800
From: HuangXuejun <hxjun@yahoo.com>
X-Mailer: Mozilla 4.07 [en] (Win95; I)
MIME-Version: 1.0
To: gonghua <gonghua@online.sh.cn>, lancea@sybase.com
Subject: Re: how can i retrive Chinese character correctly using jConnect 3.0 in Applet
References: <362325FF.21BAB6E1@yahoo.com> <362D646B.558FF708@online.sh.cn> <362DA73F.3A5A773C@yahoo.com> <362E81CA.27AC753B@online.sh.cn>
Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: 7bit
Newsgroups: sybase.public.jconnect30
Lines: 26
Path: forums-1-dub!forums-master.sybase.com!forums.powersoft.com
Xref: forums-1-dub sybase.public.jconnect30:370
Article PK: 255769

Thank you everyone , maybe i found the reason , but i don't know why .
it runs all ok in java Application , but often occure JZ0I6 and JZ006 in
java Applet . maybe , this is not a problem of jConnect .
i do the following test in PWin95 and EWinNT4.0 SP3 :
there are four types of control in my Applet :
Label , TextField , TextArea and Choice .
step 1: in the init method of Applet , use the method setText or addItem
to set a Chinese String to the control . it all appears correct on
the control .
step 2: use jConnect to retrieve some Chinese string from Sybase ASE 11.5 ,
the set them to the controls , now , Label and Choice display the
Chinese
string correctly , but the TextArea and TextField do not display the
Chinese
correctly .
and when i try to set the CHARSET property of jConnect using
'eucgb','cp850','iso_1'...etc ,
all the controls can not display Chinese correctly . (it makes no effect by set
VERSIONSTRING
to 2 or 3)


gonghua Posted on 1998-10-21 04:33:06.0Z
Message-ID: <362D6402.74E0FACD@online.sh.cn>
Date: Wed, 21 Oct 1998 12:33:06 +0800
From: gonghua <gonghua@online.sh.cn>
X-Mailer: Mozilla 4.07 [en] (WinNT; I)
MIME-Version: 1.0
To: HuangXuejun <hxjun@yahoo.com>
Subject: Re: how can i retrive Chinese character correctly using jConnect 3.0 in Applet
References: <362325FF.21BAB6E1@yahoo.com>
Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: 7bit
Newsgroups: sybase.public.jconnect30
Lines: 18
Path: forums-1-dub!forums-master.sybase.com!forums.powersoft.com
Xref: forums-1-dub sybase.public.jconnect30:376
Article PK: 255775

Hi :
Try to use nchar or nvarchar type in the database.
and you can use the charset eucgb and use the version 2,
because if you use version 3, it will ingore the charset variable
and
use the database default charset .
good luck!

HuangXuejun wrote:

> i write a java application using jConnect 3.0 , it can retrieve Chinese
> character correctly
> from ASE 11.5 , but , when i turned the application to Applet , i can
> not work properly , the result in English is all ok , but result in
> Chinese may be ????? or other strange code .
> (i had set the charset to 'eucgb' and versionstring to '3')
> thank you !


gonghua Posted on 1998-10-21 04:32:43.0Z
Message-ID: <362D63EB.2472FCA0@online.sh.cn>
Date: Wed, 21 Oct 1998 12:32:43 +0800
From: gonghua <gonghua@online.sh.cn>
X-Mailer: Mozilla 4.07 [en] (WinNT; I)
MIME-Version: 1.0
To: HuangXuejun <hxjun@yahoo.com>
Subject: Re: how can i retrive Chinese character correctly using jConnect 3.0 in Applet
References: <362325FF.21BAB6E1@yahoo.com>
Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: 7bit
Newsgroups: sybase.public.jconnect30
Lines: 18
Path: forums-1-dub!forums-master.sybase.com!forums.powersoft.com
Xref: forums-1-dub sybase.public.jconnect30:377
Article PK: 255778

Hi :
Try to use nchar or nvarchar type in the database.
and you can use the charset eucgb and use the version 2,
because if you use version 3, it will ingore the charset variable
and
use the database default charset .
good luck!

HuangXuejun wrote:

> i write a java application using jConnect 3.0 , it can retrieve Chinese
> character correctly
> from ASE 11.5 , but , when i turned the application to Applet , i can
> not work properly , the result in English is all ok , but result in
> Chinese may be ????? or other strange code .
> (i had set the charset to 'eucgb' and versionstring to '3')
> thank you !