Results 1 to 4 of 4
- 03-02-2009, 04:08 PM #1
Member
- Join Date
- Mar 2009
- Posts
- 2
- Rep Power
- 0
Having trouble using multi-byte charset?
Hi there,
Can someone assist me on below?
I would like to write a multi-byte string in a flat file where stipulated length is provided.
Field A = “xyz” (all are Chinese chars and each char occupies 2 bytes)
Say, space provided for field A in database is 5 bytes, and I would like to store first two chars (x and y here) and save a blank space. I don’t want to save third
Char ‘z’ since there is no sufficient space.
How can I achieve this? Any help would be highly appreciated.
Regards,
Devarajan
- 03-02-2009, 05:28 PM #2
Java Code:String.getBytes()
Introduction to Programming Using Java.
Cybercartography: A new theoretical construct proposed by D.R. Fraser Taylor
- 03-02-2009, 06:24 PM #3
Member
- Join Date
- Mar 2009
- Posts
- 2
- Rep Power
- 0
HI Nicholas,
Thanks for your reply.
But my problem is quite different..
I would like to store either xyz .. or xy alone(when 'z' couldnt be stored)
So,I would like to know how to check if a multi-byte char has been stored partially?
Is there any method in API or any idea?
Thanks,
DevarajanLast edited by devu1982; 03-02-2009 at 06:33 PM.
- 03-03-2009, 04:00 PM #4
Similar Threads
-
Byte Array
By sandor in forum New To JavaReplies: 12Last Post: 01-15-2009, 03:31 AM -
using Byte arrays
By mew in forum New To JavaReplies: 2Last Post: 01-30-2008, 03:54 AM -
BufferedImage to Byte
By Java Tip in forum Java TipReplies: 0Last Post: 01-22-2008, 08:17 PM -
int to byte
By ravian in forum New To JavaReplies: 1Last Post: 01-13-2008, 07:22 PM


LinkBack URL
About LinkBacks
Reply With Quote
Bookmarks