Reading Japanese characters from a JSP/HTML form.

I have a JSP/STRUTS/WEBLOGIC/ORACLE setup. I am able to get Japanese characters in database to be shown on the screen ( html ). However the users now want to enter Japanese characters on the screen and want to save these unicode characters in DB. How should I go about it?
I am using html:text tag for the input fields in the JSP. No matter what I try I am getting invalid characters..Thanks in advance.

hi debo_nair,
if i am not mistaken the japanese characters might be getting stored in the database as '?????' and other junk characters....
well I used the following technique:
1.retrieve the string from the text field and
2.convert it using the following method...
new String getbytes("the string entered in the text field","ISO-8859")
3.Next , store the string in the database
the syntax may be incorrect but just refer to any java book to get the correct syntax
regds

Similar Messages

  • Reading Japanese Characters from Properties File

    I am running on Windows 2000 (English). Can any one suggest on how to read Japanese Characters from a ".properties" file.
    TIA

    look at ResourceBundle and unicode encoding,
    Jim

  • Create Form Beans from JSP/HTML forms

    In the Builder certification objectives, there is one called "Create Form Beans from JSP/HTML forms". How can I do that? How can I create a form beam starting from the JSP form or HTML form?

    Guys, no one from forum can answer this question?

  • Japanese characters from args giving question marks on Japanese OS

    Hi,
    We are internationalising our product to japanese, and one of the features is to be able to open a file containing japanese characters from a double click on a japanese windows OS.
    The double click is set up in the registry, and indeed it works properly for most characters. There are a few characters though (unicode character 20060 among them) that it doesn't work for, and what happens is that between the double clicking of the file, and the command line name of the file to open ("%1" in the registry / args[0] in java), the character in question is converted into the literal character for "?" (ascii 63), and java can't open the file.
    Testing wordpad directly with this character is fine, the file opens. I've written a simple C++ app and a simple JAVA app which fork wordpad with the fileName param passed to it from the registry, and it didn't open the file passed because of that character.
    So our java application, a simple java program and a simple C++ program can't resolve the fileName passed to it because of this character.
    The thing is, wordpad is using the same regedit method to get its parameters as we do ("appName.exe" "%1" in shell/open/command) and it opens files containing this character without a problem.
    Any ideas on what I'm missing?
    Thanks very much
    Jack

    Hi,
    We are internationalising our product to japanese,
    and one of the features is to be able to open a file
    containing japanese characters from a double click on
    a japanese windows OS.
    The double click is set up in the registry, and
    indeed it works properly for most characters. There
    are a few characters though (unicode character 20060
    among them) that it doesn't work for, and what
    happens is that between the double clicking of the
    file, and the command line name of the file to open
    ("%1" in the registry / args[0] in java), the
    character in question is converted into the literal
    character for "?" (ascii 63), and java can't open the
    file.
    Testing wordpad directly with this character is fine,
    the file opens. I've written a simple C++ app and a
    simple JAVA app which fork wordpad with the fileName
    param passed to it from the registry, and it didn't
    open the file passed because of that character.
    So our java application, a simple java program and a
    simple C++ program can't resolve the fileName passed
    to it because of this character.
    The thing is, wordpad is using the same regedit
    method to get its parameters as we do ("appName.exe"
    "%1" in shell/open/command) and it opens files
    containing this character without a problem.
    Any ideas on what I'm missing?
    Thanks very much
    JackUnicode 20060 belongs to an extended part of JIS Kanji code set and there can be many
    applications or systems that do not support those characters. Shift_JIS doesn't and
    EUC-JP use 24 bit code for representig those chars which, unfortunately, aren't supported
    by most exixting apps.

  • Showing Japanese characters from Report Builder

    Hi , We've some problem showing the Japanese characters using Oracle Report builder 6i (6.0.8.17.0).
    Our database version is Oracle9i-9.0.1.4.0 and
    we'r using the DB character set as US7ASCII and National charecter set as UTF8 (Tried with AL16UTF16 but it's supported as per Oracle-metalink). We'r using Solaris 9 (OS 5.9) to invoke the Report Builder.
    Japanese characters are able to insert and select from SQL prompt using Japanese Terminal..
    But from the Report builder when we run the Report, we'r seeing some junk characters. Please help if anybody has worked on showing the Japanese characters from Report builder.
    Thanks
    -TN Reddy

    Hi Vinod and Sripathy,
    Thanks much for your feedback. We did some testing and it manage to get the results from txt/html/xml outputs but still have problem with post script format.We'r Checking this now..
    The prblem was UTF-8 was installed at the OS level (solaris 9).
    Anyway, Thank you very much.
    Regards
    -TN Reddy

  • Tomcat unable to read accented characters from MySQL

    Folks,
    Can anyone help with me this problem?
    It seems that my version of Tomcat is unable to read accented characters from my MySQL Database.
    I've checked in the Database and the characters are all correctly represented there. But when, in my servlet code, I do:
    String author = results.getString("author_surname");If the String contains any accented character then the character shows as a '?'. (Even before it gets to the JSP - I'm writing the results straight to catalina.out).
    Looking around these forums I found that some people suggested adding
    ?useUnicode=TRUE&characterEncoding=UTF-8;to the end of my jdbc url. As in:
    <ResourceParams name="jdbc/connection">
    //a whole load of other params
      <parameter>
        <name>url</name>
         <value>jdbc:mysql://localhost:3306/bookshop?useUnicode=TRUE&characterEncoding=UTF-8</value>
      </parameter>
    </ResourceParams>inside my server.xml
    But it doesn't seem to make any difference. In addition, I doubt I even need to use Unicode as the accents I need are only: ����� etc.
    (Incidentally, writing that line into my server.xml, tomcat complains that it should finish with a semi-colon. Is that correct? Even if I put in the semi-colon, it still complains!!)
    Any suggestions on this would be much appreciated. Thank you.

    user13109986 wrote:
    HI,
    From http://download.oracle.com/docs/cd/B10501_01/server.920/a96529/ch9.htm
    My understanding is the JDBC Api converts the string from the database to UTF-16.. If so is there any way to disable the UTF-16 encoding at JDBC API?That's exactly what it's supposed to do. There isn't even any concept of what it would mean to disable that: Java characters are UTF-16 representations of Unicode code-points, so there isn't anything else it could do.
    I still suspect the JDBC part is working correctly and your writing-to-file isn't. I found this quote in the Wikipedia article on Windows-1256:
    Windows-1256 is a code page used to write Arabic (and possibly some other languages that use Arabic script, like Persian) under Microsoft Windows. This code page is not compatible with ISO 8859-6 and MacArabic encodings.So was there a particular reason you chose Cp1256 and not ISO-8859-6 as the charset to write to the file with?

  • Reading Japanese characters.

    I am not able to read Japanese characters in Unicode in Sun machines. Has any body experienced this problem before. I hade a Shift-SJIS encoding file. I later ran the native2ascii -encoding SJIS on the file and when I bring up my application. I do not see the Japanese characters at all.
    Thanks,

    I have a file in Shift-JIS. I then compile using javac -encoding SJIS to let the compiler know that it is a Shift-JIS file. I am not able to get it running in Solaris machine. Do I need to do something different for this. I have JapStrings_ja.java file which has the strings in Shift-SJIS.
    Thanks

  • Migrating Japanese Characters from MS SQL Server 2000 to Oracle 9i usng Jsp

    Hi ,
    I have a situation where the Japanese characters are to be migrated from MS SQL Server 2000 to Oracle 91 and then render the same using JSP.
    I followed the below approach,
    1. Extract the Japanese data from MS SQL Server and generate an XML
    2. Parse the XML and store it into Oracle 9i database which is of UTF-8 encoding.
    3. On retreiving and rendering using the Shift-JIS adds few junk characters additionally.
    When I try to copy paste the Japanese contents from XML to a text file, it is working fine.
    Could some one help me in resolving this issue?
    It is very urgent, and any help would be greatly appreciated.

    There is documentation in the reference guide sent with the workbench, there is this discussion forum, the support web page (which includes tech notes and FAQ's), and the company specific procedural language documentation.
    There is also an older document for use with the old sybase toolkits which may be obscelete, and there are some internal documents which were for internal consumption.
    Turloch
    Oracle Migration Workbench Team

  • XSL-FO unable to read special characters from the XML file

    Team,
    please help on issue, when trying to read the text from XML file (Special characters like bullet). It is displaying as Question mark(?) in output in place of bullet..please proved any soultion.

    The "?" signals a character set mismatch issue - http://www.oracle.com/technetwork/database/globalization/nls-lang-099431.html - between client and database software

  • How do I copy/paste Japanese characters from Word to ID CS5.5?

    I'm using ID CS5.5 as my layout program and helping my girlfriend lay out a children's book she's working on. She's a Spanish professor at a local university. So far, we've done the text in English, Spanish, French, Portuguese, and German. But she also wants to provide the book in Japanese, so had one of her colleagues, who is from Japan, translate it and provided the translation to me in the body of an e-mail, which I copied and pasted into Word. However, when I pasted it into the InDesign layout, I get the pink boxes with the "x", indicating that particular font isn't installed. I understand this. I selected one of the Japanese characters and checked the info in Word, finding that it is CJK Unified Ideograph, character code 69D8, keyboard shortcut 69D8, Alt+x. Here is the character: 様
    Here is one of the sentences in Japanese:
    カルロスです。ぼくにはしんゆうがいて、ジャバリとジョッシュといいます。ぼくらはいつもいっしょにあそびます。みためはちがうけど、にているとこもたくさんあります
    Is it absolutely impossible to accomplish our goal without having the particular Japanese typset installed on my system that he's using? It's showing up here and in Word. ????? I've done a search and did a lot of reading, but didn't find my exact issue, so just wanted to start fresh and hopefully get some helpful input. If this has been discussed before, I apologize, but didn't find it.
    Thanks
    DC

    Your line breaks will most likely be incorrect if you don't turn on the Japanese Composer.
    It is almost absolutely impossible to accomplish your goal without having a font - any font - installed on your system that has that glyph. However, if it's showing up in Word, than means that you must have that glyph installed, right? What font are you trying to use in InDesign? You might already know that Word will auto-substitute fonts when it encounters a missing glyph, so we really don't know what font is being used to render that one glyph. The whole sentence might be in MS Mincho but one glyph might be pulled from another font if MS Mincho doesn't have that glyph.
    That being said, you're going to break it if you don't know how to set Japanese type in ID. It's not something where you can just copy text out of email and paste into your English layout.

  • Using JSP, HTML Form for uploading image  in order to be saved into a db

    I have a HTML form and I am using <input type="file"> tag. The problem is that I don't know the Java code needed for the JSP page in order to get through the path and get the image(of course I refer to binary object). Below there is the html code
    <%@ page language="java" import="java.sql.*, java.awt.*, java.awt.Event, java.util.*, java.io.*, javax.servlet.*"%>
    <html>
    <head>
    </head>
    <body>
    <div align="left"></div>
    <form action="action.jsp" method="POST" name="form"
    <h1>Add Data</h1>
    <table>
    <tr>
    <td>Name</td>
    <td><input type="text" name="Name" value="" /></td>
    </tr>
    <tr>
    <td>Last Name</td>
    <td><input type="text" name="lastname" value=""/></td>
    </tr>
    <tr>
    <td>Studies</td>
    <td><textarea name="studies" rows="4" cols="20" >
    </textarea>
    </td>
    </tr>
    <tr>
    <td>General Data</td>
    <td><textarea name="gendata" rows="4" cols="20">
    </textarea>
    </td>
    </tr>
    <tr>
    <td>Photo</td>
    <td><input type="File" name="photo"/></td>
    </tr>
    <tr>
    <td> <input type="submit" > </td>
    </tr>
    </table>
    </form>
    If you want to view the Personnel List click here<br>
    Go to index
    </body>
    </html>

    A JSP should not be involved in this. The browser will offer a way to specify a file, and the target of the form should be a servlet that can handle multipart uploads. JSPs should not process any input.
    More info: http://www.jguru.com/faq/view.jsp?EID=160 or Google

  • Jsp/html form- servlet- xml parsing

    does anyone have an example or know of a place where I can get code
    which passes XML from jsp/html to servlet which parses the xml???
    will be appreciated..........thanks

    Hi,
    Are u trying to acheive indpendent of browser solution or just want to know the things..
    well,I have one idea ok.
    Using JavaScript Constructs the XmL as u want, "let say
    <root><name>Lokesh</name><age>25</age></root>" before submitting the page(I mean frm.submit()) assign to a hidden variable, since you have post kind of submit back at the servlet from the request object get the value and store it as String and using StringReader you just parse the XML
    Just try the above one the below code
         public org.w3c.dom.Document getXMLDocument() throws IllegalStateException,Exception
                        if (!containsXMLDocument())
                                  throw new IllegalStateException("This request does not contain an XMLDocument");
                   javax.xml.parsers.DocumentBuilderFactory dbf=javax.xml.parsers.DocumentBuilderFactory.newInstance();
                   javax.xml.parsers.DocumentBuilder db=dbf.newDocumentBuilder();
                   java.io.StringReader strRdr=new java.io.StringReader(_xmlString);
                   org.xml.sax.InputSource ipSrc=new org.xml.sax.InputSource(strRdr);
                   org.w3c.dom.Document doc=db.parse(ipSrc);
                   return doc;
    best of luck..
    With Regards
    Lokesh T.C

  • Reading special characters from a flat file and inserting into DB

    I'm reading data with special characters like . etc from a flat file , assigning the data to variable in my anonymous block and inserting into my DB. But the show up as inverted ? s. Any clues about how to do this?
    If i try to do the insert directly it works. It seems like the error occurs when reading this data into a variable
    thanks for the help
    Lalit Bhatia

    lalit, this is probably an character set problem, the default on Database creation tends to be 7bit Ascii which does not support special characters, it's been a while since I set up a db in this way, but you need to change settings in oracle.ini. The db will need to be restarted for this. Also, to check current settings try:
    select * from NLS_DATABASE_PARAMETERS
    You want an 8bit, unicode or multibyte character set. Sorry I cannot remember moer off the top of my head, try searching on NLS or character set

  • Read japanese char from oracle

    I have a database column stores japanese char in Shift-JIS encoding. A
    perl script can read the database and display the result on browser.
    But If i try the get the japanese string in Java using JDBC. I got an
    exception:
    String text = resultset.getString(1);
    Exception in main(): java.sql.SQLException: Fail to convert between
    UTF8 and UCS2: failUTF8Conv
    I wonder why I getting this exception and how to fix this?
    thanks

    Hi
    We had faced the same problem.
    Problem was with oracle jdbc thin driver.
    We change the driver from THIN to OCI that works fine.
    Try this option and pls let me know.
    Regards,
    Aslam A.S

  • Read last characters from a file

    Hey All:
    i'm a novice when it comes to powershell- but this is what i'm trying to do.
    I have the following command-
    gwmi-classwin32_computersystem|selectName|out-filec:\computername.txt
    I want to then read the last three characters of the computername from the file. If there is a 'cleaner' approach
    please enlighten me.
    Thanks for all the help
    -Matlock

    Hi,
    Here's a method you can use:
    $name = (Get-WmiObject Win32_ComputerSystem).Name
    $shortName = $name.SubString($name.Length - 3)
    $shortName
    EDIT: Show on the draw, see Tommy's response above.
    Don't retire TechNet! -
    (Don't give up yet - 12,700+ strong and growing)

Maybe you are looking for

  • To upgrade or Not to upgrade this is the Question? What is the Answer!

    Does Adobe expect Design & Prepress studios like the one I run to upgrade all out copies to get the latest version of Acrobat 9 before they have fixed the problems that are in Acrobat 8? I see that the latest version is released now but there is stil

  • OPMN fails in cluster environment after the machie reboots.

    Dear All: Have you ever meet the following problem or have any suggestion for it? Thanks a lot. There are machine A and B have been setup successfully in a cluster environment, everything is fine. However, after the machine B reboots, the Oracle BI S

  • All Information regarding Change and Transport management System in SAP

    Hello Experts, Iam into Basis . I need all information ,fundamentals and concepts over Change and Transport management system in SAP .Its fundamentals,the way it works ,how requests r transporteded etc.  I want more of this information in regards to

  • How to  read list output into itab? - URGENT

    hai experts, how to read current report output for further validation i need all data which is showing in output. my req is, to read list output all data put into itab. reward avail for useful answer.... regards, jai.m

  • Unexplained artwork "jump" on rollover

    I created the attached "tip" button with the up and down arrows.  The TIP word was from AI the triangles I realized I needed one in FC. I created the whole thing in the "over" state, then grouped the word & two arrows.  Copied and paste to the other