• Post Reply Bookmark Topic Watch Topic
  • New Topic

encoded string reading from problem database /itext -very urgent  RSS feed

 
vamshiambati krishna
Greenhorn
Posts: 4
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hi ,
i am using i text to create pdfs ,
iam reading encoded strings from database (varchar-2),which are read as normal strings i.e if i store an encoded string "\u0c05" , i am not able to display actual decoded value of that string . it is printing as normal string as \u0c05 in the pdf .how to retrive that encoded strings from database.
any help is appresiated,

thanks,
vamshi
 
Ulf Dittmer
Rancher
Posts: 42972
73
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Something like "\u0c05" is a Java-specific notation; it doesn't really make sense to put that into a database. The proper way to store Unicode in a database is to set the encoding of that DB to Unicode, and then to store all text in Unicode. That way you never have to worry about encoding, or about converting the text if you happen to access the DB using some other programming language than Java.

I don't see anything iText-specific in this question, by the way.
[ December 29, 2008: Message edited by: Ulf Dittmer ]
 
vamshiambati krishna
Greenhorn
Posts: 4
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
but i text understands unicodes like "\u0c05" to create pdf, if we change the dabase encoding , can we able to store the unicodes like this \u0c05, i already tried with changing table encoding,but still i am retriving unicode as normal string.can you give me any detailshow to store and retrive unicodes from database

thanks
-vamshi
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!