Who knows how to read the Chinese Characters from JDBC?

I wrote two files. One is a jsp file, the other is java file. But in the jsp file it cannot print the Chinese characters, only can print the English characters. I have changed the Character Coding of the browser, but it has no effects. However, the java file works much fine. It can print the both English and Chinese characters.
This is a part of my codes.
String query="SELECT * FROM MyDB.dbo.BookList WHERE bookname like \'Java%\'";
ResultSet rs=sm.executeQuery(query);
rs.next();
out.println(rs.getString(1));
MyDB is a database in the SQL server.

Hi,
Did you try setting the contentType/charset of the JSP page? The default is latin, I think.
<%@ page ... contentType="text/html; charset=character_set" ... %>
Maybe this helps? At least it could give you a start of where to look...
Best,
Guy
http://www.atomikos.com - JTA transactions

Similar Messages

  • How to read the Chinese characters set?

    Hello, everyone,
    I have a serial problem about using JavaMail.
    When i read the mail which contain Chinese characters set ( e.g. Big5 ). It will display a unreadable coding.
    Example: " =?big5?B?aGl5YXRvbw==?= "
    How to solve it? Please give me a solution if you know that. I am looking forward to receiving you reply.
    hiyatoo,

    As I know, you can use this:
    msg.setContent(messageText.toString()), "text/html;charset=Big5");
    It works well at my JavaMail API. By the way, your computer msut support Chinese characters.
    Hope this can help.

  • I have a problem with mail.  the spelling and grammer check box before sending the messege is no longer there.  I did everything but cannot get it back.  is ther anyone who knows how to get the box with spelling and grammer checks before sending

    i have a problem with mail.  the spelling and grammer check box before sending the messege is no longer there.  I did everything but cannot get it back.  is ther anyone who knows how to get the box with spelling and grammer checks before sending the mail.
    Also the mail is acting very funny by not getting the rules work in a proper method.  Is ther a software to repair mail.

    i did both of them, but still the while sending the mail the diolog box is not showing up and also the spelling and grammer does not do the spelling check. 
    This problem just started for about 3 to 4 days now.  earlier it was working normally.

  • Anyone know how to stop the "activate" box from blocking usage of a perfectly legal copy of Ilisten? I want to help my dyslexic grandson and this box, including the activation code, keeps popping up, keeping me from using the software. I activated the pro

    Anyone know how to stop the "activate" box from blocking usage of a perfectly legal copy of Ilisten? I want to help my dyslexic grandson and this box, including the activation code, keeps popping up, keeping me from using the software. I activated the program and did a few profile building sessions, now it pops up each time I start the program, blocking me from using it. Help sure would be appreciated.
    Jay

    I looked at your post this morning and did not know enough to respond, other than to find out that links to iListen now go to newer, renamed software. Considering it's been nine hours with no response, I'm suspecting few people here have experience with that software. You could contact the current copmany that used to sell that package and see if they have any archived support info.
    BTW: please check you entry for "Mac OS" in your profile. It says iOS, which cannot run on an iMac. iOS is the system for phone and iPads but can't run on Mac computers. Do "About this Mac" from the Apple menu and see what it says about the OS version. Should look like this:
    If the "Processor" line says "Intel," you have a newer Mac than the old modles this forum covers; Intel iMac have their very own forum here:
    iMac (Intel)

  • Does anyone know how to remove the fisheye effect from a gopro camera, remove it with premiere pro c

    Does anyone know how to remove the fisheye effect from a gopro camera, remove it with premiere pro cc.

    Use the Lens Distortion effect, set curvature to your liking.

  • Does anyone know how to prevent the YouTube volume from going up automatically?  I keep my volume down and it increases automatically when I play a video.

    Does anyone know how to prevent the YouTube volume from going up automatically?  I keep my volume down and it increases automatically when I play a video.

    Have you tried Windows Update in the Control Panel?
    Many times it will find the newest supported drivers for Hardware.
    Just be sure to install everything not just the Important ones.
    Let us know if this helps.

  • Hello, everybody, who know how to use the function READ_TEXT

    Hello , everybody,  I came across a program in which there is a function  READ_TEXT, what is it used for ? please specify the parameters  id object 
    . Thank you in advance, mate.
             Best regards                                                                               
    Frank
    CALL FUNCTION 'READ_TEXT'
          EXPORTING
        CLIENT                        = SY-MANDT
            id                            = '0207'
            language                      = sy-langu
            name                          = tmp_name
            object                        = 'VBBK'
        ARCHIVE_HANDLE                = 0
        LOCAL_CAT                     = ' '
      IMPORTING
        HEADER                        =
          TABLES
            lines                         = text_itab
         EXCEPTIONS
           id                            = 1
           language                      = 2
           name                          = 3
           not_found                     = 4
           object                        = 5
           reference_check               = 6
           wrong_access_to_archive       = 7
           OTHERS                        = 8

    Refer this link:
    http://help.sap.com/saphelp_nw04/helpdata/en/d6/0db764494511d182b70000e829fbfe/frameset.htm
    READ_TEXT provides a text for the application program in the specified work areas.
    The function module reads the desired text from the text file, the text memory, or the archive. You must fully specify the text using OBJECT, NAME, ID, and LANGUAGE. An internal work area can hold only one text; therefore, generic specifications are not allowed with these options.
    After successful reading, the system places header information and text lines into the work areas specified with HEADER and LINES.
    If a reference text is used, SAPscript automatically processes the reference chain and provides the text lines found in the text at the end of the chain. If an error occurs, the system leaves the function module and triggers the exception REFERENCE_CHECK.
    Function call:
    CALL FUNCTION 'READ_TEXT'
    EXPORTING CLIENT = SY-MANDT
    OBJECT = ?...
    NAME = ?...
    ID = ?...
    LANGUAGE = ?...
    ARCHIVE_HANDLE = 0
    IMPORTING HEADER =
    TABLES LINES = ?...
    EXCEPTIONS ID =
    LANGUAGE =
    NAME =
    NOT_FOUND =
    OBJECT =
    REFERENCE_CHECK =
    WRONG_ACCESS_TO_ARCHIVE =
    Export parameters:
    CLIENT
    Specify the client under which the text is stored. If you omit this parameter, the system uses the current client as default.
    Reference field: SY-MANDT
    Default value: SY-MANDT
    OBJECT
    Enter the name of the text object to which the text is allocated. Table TTXOB contains the valid objects.
    Reference field: THEAD-TDOBJECT
    NAME
    Enter the name of the text module. The name may be up to 70 characters long. Its internal structure depends on the text object used.
    Reference field: THEAD-TDNAME
    ID
    Enter the text ID of the text module. Table TTXID contains the valid text IDs, depending on the text object.
    Reference field: THEAD-TDID
    LANGUAGE
    Enter the language key of the text module. The system accepts only languages that are defined in table T002.
    Reference field: THEAD-TDSPRAS
    ARCHIVE_HANDLE
    If you want to read the text from the archive, you must enter a handle here. The system uses it to access the archive. You can create the handle using the function module ACHIVE_OPEN_FOR_READ.
    The value '0' indicates that you do not want to read the text from the archive.
    Reference field: SY-TABIX
    Default value: 0
    Import parameters:
    HEADER
    If the system finds the desired text, it returns the text header in this parameter.
    Structure: THEAD
    Table parameters:
    LINES
    The table contains all text lines that belong to the text read.
    Structure: TLINE
    Exceptions:
    ID
    The text ID specified in the parameter ID does not exist in table TTXID. It must be defined there together with the object of the text module.
    LANGUAGE
    The parameter LANGUAGE contains a language key that does not exist in table T002.
    NAME
    The parameter NAME contains the name of a text module that does not correspond to the SAPscript conventions.
    Possible errors:
    The field contains only blanks.
    The field contains the invalid characters ‘*’ or ‘,’.
    OBJECT
    The parameter OBJECT contains the name of a text object that does not exist in table TTXOB.
    NOT_FOUND
    The system did not find the specified text module.
    REFERENCE_CHECK
    The text module to be read has no text lines of its own but refers to the lines of another text module. This reference chain can include several levels. For the current text, the chain is interrupted, that is, one of the text modules referred to in the chain no longer exists.
    WRONG_ACCESS_ TO_ARCHIVE
    The exception WRONG_ACCESS_TO_ARCHIVE is triggered if an archive is accessed using an incorrect or non-existing archive handle or an incorrect mode (that is, read if the archive is open for writing or vice versa).
    Raja T

  • How to read the field type from field id of DynamicFldTbl

    Hi,
    In my application, i am using DynamicFldTbl, whch parses FML32 field table definition file. My field table definition file contains information about field names and its types.
    I checked the API of DynamicFldTbl and didn't find any API to get the field type from field it.
    Any way to read the field type from field id?
    Thanks in advance
    Raguraman

    Hi Raguraman,
    Once you have the field table, you can then create an FML32 buffer (TypedFML32) using the constructor that takes a field table, and then use the Fldtype() method on the specific field ID you wish to get the type of. I know this is sort of tedious and we should provide Fldtype() and some others on the field table class directly.
    Regards,
    Todd Little
    Oracle Tuxedo Chief Architect

  • Is there anyone who knows how to fix the CD burning issue?

    It appears that with an upgrade to iTunes 6.02, I can't burn an audio Cd. I have read through many of the discussion comments to look for anwswers and it appears that MANY of we iTunes users are frustrated with the inability of iTunes to burn audio CD's.
    Much like everyone else, I create my playlist, and when I click on burn, itunes checks the media, acesses the playlist and then freezes. I have to cntrlaltdel to exit the program so I don't get any error message number. I do send the error message by email when prompted. I have run a diagnostic... details below.
    Microsoft Windows XP Home Edition Service Pack 2 (Build 2600)
    Seanix Technology Inc MS-6741
    iTunes 6.0.2.23
    CD Driver 2.0.4.3
    CD Driver DLL 2.0.3.2
    LowerFilters: PxHelp20 (2.0.0.0), ASAPIW2K (6.0.2.0),
    UpperFilters: GEARAspiWDM (2.0.4.3),
    Video Driver: VIA/S3G UniChromeII Graphics\SVIA/S3G UniChromeII Graphics Adapter
    IDE\DiskHDS722516VLAT20_______________________V34OA6EA, Bus Type ATA, Bus Address [0,0]
    USBSTOR\DiskIOMEGA_ZIP_100________02.U, Bus Type USB
    IDE\CdRomLITE-ONDVDRW_SOHW-1693S________________KS0A___, Bus Type ATA, Bus Address [1,0]
    Some computers need an update to the ATA or IDE bus driver, or Intel chipset. If iTunes has problems recognizing CDs or hanging or crashing while importing or burning CDs, check the support site for the manufacturer of your computer or motherboard.
    Current user is administrator.
    D: LITE-ON DVDRW SOHW-1693S, Rev KS0A
    Media in drive is blank.
    Get drive speed succeeded.
    The drive CDR speeds are: 8 16 24 32 40 48.
    The drive CDRW speeds are: 8.
    The drive DVDR speeds are: 8.
    The drive DVDRW speeds are: 8.
    Nero and WinMedia player still burn and I can rip tunes off of my CD's with iTunes so the burner is not the problem. The Cicero/Seanix websites are useless places to get answers too. Does anyone know how to get into direct contact with someone from Apple? Please help.
    Take care
    islandbrian

    iOS 7: Help with how to fix a crashing app on iPhone, iPad (Mini), and iPod Touch
    http://teachmeios.com/help-with-how-to-fix-a-crashing-app-on-iphone-ipad-mini-an d-ipod-touch/
    Try this  - Reset the iPad by holding down on the Sleep and Home buttons at the same time for about 10-15 seconds until the Apple Logo appears - ignore the red slider - let go of the buttons. (This is equivalent to rebooting your computer.) No data/files will be erased. http://support.apple.com/kb/ht1430
    Troubleshooting apps purchased from the App Store
    http://support.apple.com/kb/TS1702
    Downloading Past Purchases from the iTunes Store, App Store and iBooks Store
    http://support.apple.com/kb/ht2519
    Send feedback/suggestions to Apple.
    http://www.apple.com/feedback/ipad.html
     Cheers, Tom

  • Who knows: How to divide the request.getInputStream()?

    I use a form in a web page to update files, the form code is
    <form action="/Mywork/servlet/fileupdate1" method="post" enctype="multipart/form-data">
    <p>
    Please select a file1 to upload: <input type="file" name="foo">
    </p>
    <p>
    Please select a file2 to upload:<input type="file" name="foo1">
    </p>
    <input type="submit" value="Upload File!">
    </form>
    and the "fileupdate1" servlet which the "action" in the form tag refers to will get the inputstream by
    "ServletInputStream servIn = request.getInputStream();", and create new OutputFileStream in the disk. But
    new files which the servlet stored always have some additional codes "
    -----------------------------7d419320202be
    Content-Disposition: form-data; name="foo"; filename="H:\Documents and
    Settings\administrator\desktop\ee.java"
    Content-Type: application/octet-stream
    If I updating two files, each file will has these kinds of codes and the two files only have one inputstream. I don't
    how to remove these additional codes and how to divide the stream into pieces according to the updated-file-size.
    I don't know wether I say it clearly?And
    does anyone know the reasons and can help me?
    Thank you very much.

    Use something like Jakarta Commons FileUpload to process the multipart/form-data request:
    http://jakarta.apache.org/commons/fileupload/

  • HT1688 does anyone know how to transfer the existing music from my itunes account that i had with an ipod to my iphone?  I had my last download on my laptop which crashed and now we have a new computer.  I had to download a new version of itunes.

    I had my itunes account on my laptop which has since crashed.   I had to buy a new computer and iinstall the new version of itunes.  It did not pull up any of my information with music library, etc.  Does anyone know how to transfer existing music from my itunes account for my ipod to my iphone?
    thanks

    Some of the information below has subsequently appeared in a document by turingtest2: Recovering your iTunes library from your iPod or iOS device - https://discussions.apple.com/docs/DOC-3991
    Your i-device was not designed for unique storage of your media. It is not a backup device and media transfer was designed for you maintaining a master copy of your media on a computer which is itself properly backed up against loss. Syncing is one way, computer to device, updating the device content to the content on the computer, not updating or restoring content on a computer. The exception is iTunes Store purchased content.
    iTunes Store: Transferring purchases from your iOS device or iPod to a computer - http://support.apple.com/kb/HT1848 - only media purchased from iTunes Store
    For transferring other items from an i-device to a computer you will have to use third party commercial software. Examples (check the web for others; this is not an exhaustive listing, nor do I have any idea if they are any good):
    - Senuti - http://www.fadingred.com/senuti/
    - Phoneview - http://www.ecamm.com/mac/phoneview/
    - MusicRescue - http://www.kennettnet.co.uk/products/musicrescue/
    - Sharepod (free) - http://download.cnet.com/SharePod/3000-2141_4-10794489.html?tag=mncol;2 - Windows
    - Snowfox/iMedia - http://www.mac-videoconverter.com/imedia-transfer-mac.html - Mac & PC
    - iexplorer (free) - http://www.macroplant.com/iexplorer/ - Mac&PC
    - Yamipod (free) - http://www.yamipod.com/main/modules/downloads/ - PC, Linux, Mac [Still updated for use on newer devices? No edits to site since 2010.]
    - 2010 Post by Zevoneer: iPod media recovery options - https://discussions.apple.com/message/11624224 - this is an older post and many of the links are also for old posts, so bear this in mind when reading them.
    Syncing to a "New" Computer or replacing a "crashed" Hard Drive - https://discussions.apple.com/docs/DOC-3141 - dates from 2008 and some outdated information now.
    Copying Content from your iPod to your Computer - The Definitive Guide - http://www.ilounge.com/index.php/articles/comments/copying-music-from-ipod-to-co mputer/ - Information about use in disk mode pertains only to older model iPods.
    Get Your Music Off of Your iPod - http://howto.wired.com/wiki/Get_Your_Music_Off_of_Your_iPod - I am not sure but this may only work with some models and not newer Touch, iPhone, or iPad.
    Additional information here https://discussions.apple.com/message/18324797

  • How to read the field value from Table Control

    Hello Experts,
    I am creating my first Table Control Screen. Basically I have to create a screen (102) with a table control which has 2 fields: A_QTY, B_QTY and 2 Buttons: SAVE, EXIT.
    When Clicked on 'SAVE' the data (MATNR) from a previous screen (101)  and the data (A_QTY, B_QTY) from the new screen (102) should be saved into a Z-table.
    Internal table t_data has 3 fields.
    MATNR
    A_QTY
    B_QTY.
    Table Control TC_RACK was declared like this:
    controls tc_rack type tableview using screen 0102.
    I/0 Fields:
    A_QTY type ZQTY.
    B_QTY type ZQTY.
    The screen Flow Logic:
    process before output.
    module status_0102.
      loop at t_data into w_data with control tc_rack.
      endloop.
    process after input.
      module exit_0102 at exit-command.
      loop at tc_rack.
      endloop.
    module user_command_0102.
    module status_0102output.
      set pf-status 'STATUS_102'.
      set titlebar 'TITLE_102'.
      describe table t_rack lines tc_rack-lines.
    endmodule.                 "status_0102 output
    process after input.
    module user_command_0615 input.
    case ok_code.
       when 'SAVE_RK'.
       when others.
    endcase.
    endmodule.                 "user_command_0102 input
    Now for eg, when the users enter values for A_QTY and B_QTY like this:
    A_QTY     B_QTY
    1000         2000
    3000         4000
    How can I read these values and pass them to T_DATA so that I can save it into Z-table?
    I greatly appreciate your help.
    I've gone through some previously posted threads and could not understand because my knowledge in this area is preliminary.
    Thanks a lot.
    Could you please let me know
    Edited by: dev a on Jan 13, 2010 2:46 PM

    Hi dev a
    You should use
      DATA: lv_name(30) TYPE c.
      FIELD-SYMBOLS: <QTY> type ZQTY.
    GET CURSOR FIELD lv_name.   "Get the field name in table control
    check sy-subrc = 0.
    assign  (lv_name) to <QTY>.  "Here you get the value in <QTY>
    check sy-subrc = 0.
    Also use <your table control>-current_line to get the table index uo're currently on.
    Hint: Do not use GET CURSOR LINE if you want to get table index since this gives you the line relative to dialog screen
    Good luck
    Dean Q.
    Edited by: Dean Q on Jan 13, 2010 11:11 PM

  • How to read the BI query from CRM system?

    Hi All,
    I have to read one BI query in CRM system. Can you please let me know how we can do that?.
    do we have any RFC present in BI system where I can pass the query name and get the result of the query in the CRM system?
    Kindly help.
    Also, do we need to make some configuration settings in CRM system to execute the BI query in CRM? If so, please let me know how we can do that?
    Regards,
    Vaibhav

    HI
    The People centic user interface is the user interface layer where the end user process the crm transactions etc.
    go to SE 80 transaction and select the application as BSP application becouse pcui is bsp based views. type crm_bsp_frame under the application field and you will get folders select the select.htm folder and right click on the mouse and click on test then you will get the popup window enter the crm system user id and password you will get the pcui floor plan for entire crm applications in the browser select the lead and opportunity transaction floor plan click on the new floor plan option. then the new popup window will open and finally you will see the lead transaction or opportunity transaction pcui view to work on . these pcui views url will inturn you can assign to the enterprise portal to log on to single sign on to EP and access the pcui application for crm marketing sales and service module areas as well along with the contact and account mangement for business partners creation screen.
    please do reward points if helpful
    Dinaker vikas

  • Anyone know how to upload the HTS files from 3rd party provider to GTS??

    We are having following files provided by 3rd party provider - CUSTOMS Info
    NAFTA ROO
    U.S. HTS
    Per provider, SAP has developed a system so that GTS users can automatically reclassify items that are effected by a change and they have asked us to program the HS data needed.
    Anyone know how to do that?
    Please advise,
    Appreciated.

    Hi Reddy,
    Thanks for your input firstly, and i still need ur advise on the HTS upload.
    1. Below is the HTS files provided by 3rd party company. and I noticed that there is 3 types of files. "DTR" , "Nom" and "Txt". Could you explain what are they? and If I need to upload them seperately?
    2. Follow the procedure your provided - "classification > upload manually HTS codes into GTS system"  Actually, I didn't find upload mannually HTS codes into GTS  IN THE SAP CUSTOM Managment.
    I tried "Load Traiff Code Numbers from XML files" and "Load Commodity code from XML file".
    1) "Load Traiff Code Numbers from XML files"
    2) "Load Commodity code from XML file".
       a)  Select all files.
            - fill in "Data Provider",
            - "XML Files"-All files selected.
            - check " Output list", "simulation mode" "Nomenclature Active" and "Activate All Text Types"
            - no "Alternative Numbering Scheme" selected, and other selected.
            Error msg found:
            - Unable to find any defined structures for tariff assignment rule set "_DHSCN"
            - Incorrect order. Enter the first file(see long text)
        b)   only select "HSCN_Txt_I_00002001001.xml", the other is the same like bove.
              1. prompted to select a "From-Time Zone",   Select "UTC+8"
              2. Simulation was carried out successfully
        c)  only select "HSCN_Nom_I_00002001002.xml", the other is the same like above.
              But I meet error for this file:  "Incorrect order. Enter the first file(see long text)"
        d)  only select "HSCN_DTR_I_00002001007.xml", the other is the same like above.
              meet error msg:
              "Unable to find any defined structures for tariff assignment rule set "_DHSCN""
    HTS xml files of China from  3rd party provider
    +++++++++++++++++++++++++++++++++++++++++++++++++++
    2008-05-02  10:53         7,483,730 HSCN_DTR_I_00002001007.xml
    2008-05-02  10:53         7,980,857 HSCN_DTR_I_00002002007.xml
    2008-05-02  10:53         7,765,896 HSCN_DTR_I_00002003007.xml
    2008-05-02  10:53         7,605,204 HSCN_DTR_I_00002004007.xml
    2008-05-02  10:53         7,743,890 HSCN_DTR_I_00002005007.xml
    2008-05-02  10:54         8,007,036 HSCN_DTR_I_00002006007.xml
    2008-05-02  10:54         3,883,316 HSCN_DTR_I_00002007007.xml
    2008-05-02  10:51         6,087,448 HSCN_Nom_I_00002001002.xml
    2008-05-02  10:51         4,955,900 HSCN_Nom_I_00002002002.xml
    2008-05-02  10:50           260,960 HSCN_Txt_I_00002001001.xml
    +++++++++++++++++++++++++++++++++++++++++++++++++++

  • How to read the Key value from the Message using the text value.. Urgent

    I need to read the Key valuefrom the message pool using the text value for the Key.. Is it possible.. Please help me with sample code..
    Thanks and Regards
    Avijit

    Avijit,
    I got your requirement. I really dont know the scenario your working on but its possible to do it. There is no direct way to do so, but complexity is in getting to know the Keys dynamically from interface.
    Here you go..
         try
              Class msgClass      = IMessageTestWDApps.class;
    //Replace IMessageTestWDApps with IMessage<Your WD Component name>
              Field keys[]      = msgClass.getFields();
              IWDTextAccessor textAccessor = wdComponentAPI.getTextAccessor();
              if(keys != null)
                   String key = "";
                   for(int index=0;index<keys.length;index++)
                        key = keys[index].getName();
                        wdComponentAPI.getMessageManager().reportSuccess("Key= "+key);
                        if(textAccessor.getText(key).equals("My message text"))
                             //your logic.
         catch(Exception cnfe)
              wdComponentAPI.getMessageManager().reportException("Exe "+cnfe.getMessage(),false);
    Regards
    Abhilash
    Message was edited by:
            Abhilash Gampa

Maybe you are looking for