Solved

How double byte alphanumeric value auto convert into single byte alphanumeric value  japanese characters

Posted on 2010-08-23
16
1,114 Views
Last Modified: 2013-11-23
How double byte alphanumeric value auto convert into single byte alphanumeric value  japanese characters
is that possible Java
0
Comment
  • 5
  • 5
  • 3
  • +2
16 Comments
 
LVL 7

Accepted Solution

by:
mquiroz earned 100 total points
ID: 33502484
I don't think is possible 'cause the number of characters in japaneses y way out of the range you could represent by a number smaller than 255 (which is the single byte maximum number of caracters), japanese at least must have a couple of thousand characters that's why you must use double byte so that the number of characters can be up to 65,000 (255 x 255)
0
 
LVL 86

Assisted Solution

by:CEHJ
CEHJ earned 200 total points
ID: 33502619
That's not possible
0
 
LVL 92

Expert Comment

by:objects
ID: 33506510
you'll have to limit the range of characters to achieve that
whats the goal?
0
Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 
LVL 20

Author Comment

by:Sathish David Kumar N
ID: 33508449
how can i limit that ??
 
restric the user to enter double byte  char
0
 
LVL 86

Expert Comment

by:CEHJ
ID: 33508486
If you want to restrict the space to a maximum of two bytes per character, you need UTF-16, not UTF-8 (which can use as many as four)
0
 
LVL 20

Author Comment

by:Sathish David Kumar N
ID: 33508508
I want only singel byte not double byte .. so i can use UTF-8 right ?
IF the user enter double byte then i give warning ?
how can i give that ??
0
 
LVL 86

Assisted Solution

by:CEHJ
CEHJ earned 200 total points
ID: 33508517
If you want to use Japanese characters you *can't* use a single byte space
0
 
LVL 20

Author Comment

by:Sathish David Kumar N
ID: 33508624
Sorry CEHJ :
Can you tell me clearly !!
0
 
LVL 86

Expert Comment

by:CEHJ
ID: 33508711
How much clearer could it be? ;) Japanese cannot be done with one byte per character
0
 
LVL 92

Expert Comment

by:objects
ID: 33508741
> I want only singel byte not double byte .. so i can use UTF-8 right ?

No, UTF-8 use 1-4 bytes for a char (ASCII uses 1 byte)
0
 
LVL 20

Author Comment

by:Sathish David Kumar N
ID: 33508769
@CEHJ
Can you refer this
https://account.edit.yahoo.co.jp/registration?.done=http%3A//mail.yahoo.co.jp/&.src=ym 
@objects
>>>>you'll have to limit the range of characters to achieve that

How can i do that ?? How can i achive
0
 
LVL 86

Expert Comment

by:CEHJ
ID: 33508837
>>Can you refer this

What am i meant to be looking at?
0
 
LVL 92

Assisted Solution

by:objects
objects earned 100 total points
ID: 33508845
its not really practical as you limit yourself to only 128 chars.

we just always use multibytes
0
 

Assisted Solution

by:spavithracse
spavithracse earned 100 total points
ID: 33509359
find the related things in the following link
http://msdn.microsoft.com/en-us/library/cc194845.aspx
0
 

Expert Comment

by:spavithracse
ID: 33509469
use this for converting

header ('Content-type: text/html; charset=utf-8');

Open in new window

0
 
LVL 20

Author Closing Comment

by:Sathish David Kumar N
ID: 33535161
Thanks
0

Featured Post

Free Tool: Subnet Calculator

The subnet calculator helps you design networks by taking an IP address and network mask and returning information such as network, broadcast address, and host range.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
Should localization be done inside spring controller 5 36
SHA2 certs for IIS AND Java? 2 121
java example issue 5 42
JDBC performance 8 28
An old method to applying the Singleton pattern in your Java code is to check if a static instance, defined in the same class that needs to be instantiated once and only once, is null and then create a new instance; otherwise, the pre-existing insta…
Go is an acronym of golang, is a programming language developed Google in 2007. Go is a new language that is mostly in the C family, with significant input from Pascal/Modula/Oberon family. Hence Go arisen as low-level language with fast compilation…
Viewers will learn one way to get user input in Java. Introduce the Scanner object: Declare the variable that stores the user input: An example prompting the user for input: Methods you need to invoke in order to properly get  user input:
Viewers will learn about basic arrays, how to declare them, and how to use them. Introduction and definition: Declare an array and cover the syntax of declaring them: Initialize every index in the created array: Example/Features of a basic arr…

680 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question