Chinese Char support in Mainframe



Support for OS/VS COBOL, VS COBOL II, COBOL for OS/390 & VM and Enterprise COBOL for z/OS

Chinese Char support in Mainframe

Postby ksathee2 » Fri Nov 04, 2011 10:46 am

Hi,
We have an requirement to support chinese characters in an existing mainframe system which is non dbcs (double byte character set) which is already a web enabled ie. the user has the online facility of this application which interacts with the mainfram for business logic.The existing will store only english characters.Is there any way to store and retrieve chinese chars without any change in the db or existing mainframe source.Is there any feasibility like receiving the chinese char from web and converting to english and storing and retreiving back and convert to chinese again whenever requested ? This should not impact my search functionality if am giving a chinese char in front end and doing a search.Please advise if any solution is there to acheive this.Response is higly solicited.

Rgds,
Sat
ksathee2
 
Posts: 3
Joined: Thu Nov 03, 2011 7:39 pm
Has thanked: 0 time
Been thanked: 0 time

Re: Chinese Char support in Mainframe

 

Re: Chinese Char support in Mainframe

Postby Robert Sample » Fri Nov 04, 2011 2:23 pm

If the application was not designed with Chinese character support in mind, then most likely either a major overhaul of the application or a complete rewrite will be required. Either case requires far, far, far more knowledge and time than you are likely to find on a forum. As enrico stated, your best bet will be to bring in a consulting firm to assist in the conversion. If this is not feasible, be prepared to spend months (at least) in learning enough to do the rewrite -- it is not a simple process that could be summarized in a few words.
Robert Sample
Global moderator
 
Posts: 3367
Joined: Sat Dec 19, 2009 8:32 pm
Location: East Dubuque, Illinois
Has thanked: 1 time
Been thanked: 222 times

Re: Chinese Char support in Mainframe

Postby BillyBoyo » Fri Nov 04, 2011 2:47 pm

Did you remember the SANTA clause on all your datanames when you compiled originally. That's the sort of magic you'd need to do exactly what you want. Christmas Magic.

Perhaps the best you can get with doing no/little work would be to investigate the web-based translators (google, bing, whatever). With ordinary text not written by a robot they can give poor results. With little context they can fail to translate at all. Maybe you can "train them" with your data, I don't know. I'd guess if you search you'll find discussion groups for these things elsewhere.

But for your system, as has been said before, there is no Magic.
BillyBoyo
Global moderator
 
Posts: 3804
Joined: Tue Jan 25, 2011 12:02 am
Has thanked: 22 times
Been thanked: 264 times

Re: Chinese Char support in Mainframe

Postby ksathee2 » Fri Nov 04, 2011 5:58 pm

Hi All,
Thanks for all your responses.This is just like tring to get a clue for an initial start.As you all suggest will try for some consultant to get some hint.Thanks guys.

SAT
ksathee2
 
Posts: 3
Joined: Thu Nov 03, 2011 7:39 pm
Has thanked: 0 time
Been thanked: 0 time

Re: Chinese Char support in Mainframe

Postby pals » Fri Dec 16, 2011 5:18 pm

I think,mainframe supports ebcidc char set.So it wud undertsand chinese characters.and my query here is how cobol file can understand chinese chars when passed to it from java source?
pals
 
Posts: 16
Joined: Thu Dec 15, 2011 12:44 pm
Has thanked: 0 time
Been thanked: 0 time

Re: Chinese Char support in Mainframe

Postby dick scherrer » Fri Dec 16, 2011 11:25 pm

Hello,

I think,mainframe supports ebcidc char set.
Yes, it does, but i do not understand how this relates to the question?

So it wud undertsand chinese characters.
How did you make this leap? Suggest you post a few of these Chinese/EBCDIC characters in hex.
Hope this helps,
d.sch.
User avatar
dick scherrer
Global moderator
 
Posts: 6304
Joined: Sat Jun 09, 2007 8:58 am
Has thanked: 3 times
Been thanked: 91 times

Re: Chinese Char support in Mainframe

Postby pals » Wed Dec 21, 2011 6:35 pm

Hi...i was trying to send 您好你怎么样 these from java to cobol file...in form "1234~您好你怎么样" string.it reaches cobol.but when it is unstringed and separated using parameter ~ and divided into two parts 1234,'this place is blank instead of chinese chars'.this i have checked by returning this variable value(which shud contain chinese chars) to java.so i mfinding solution for this.
pals
 
Posts: 16
Joined: Thu Dec 15, 2011 12:44 pm
Has thanked: 0 time
Been thanked: 0 time

Re: Chinese Char support in Mainframe

Postby BillyBoyo » Thu Dec 22, 2011 1:07 am

If it "reaches cobol" then it is still there after the UNSTRING.

You will not see Chinese characters unless you are using a Codepage which understands Chinese characters. You will see byte-values. And, probably, you won't see the byte-values because they have no display value in the Codepage you are using.

Try DISPLAY of the field from the Cobol program, and then use HEX when you display the output.

If you think a program which displays in hex from Cobol might be useful, then you can search for BBHEXD, aka The Junkbuster, on the sister-site http://ibmmainframes.com
BillyBoyo
Global moderator
 
Posts: 3804
Joined: Tue Jan 25, 2011 12:02 am
Has thanked: 22 times
Been thanked: 264 times

Re: Chinese Char support in Mainframe

Postby Robert Sample » Thu Dec 22, 2011 2:17 am

Are you trying to send your data in Unicode, or DBCS, or something else? What code page are you using in COBOL? Does that match the source? Is the input data XML? What are you going to do with the Chinese characters -- store them in a file? a DB2 database? some other database? send them somewhere else?

Do you have access to a communications monitor that will let you see exactly what is going across the line, bit by bit? If not, your chance of success goes WAY down. Because if you have so little experience you think EBCDIC handles Chinese characters, then your skill set has some extremely large holes in it.
Robert Sample
Global moderator
 
Posts: 3367
Joined: Sat Dec 19, 2009 8:32 pm
Location: East Dubuque, Illinois
Has thanked: 1 time
Been thanked: 222 times


Return to IBM Cobol

 


  • Related topics
    Replies
    Views
    Last post