Unicode display rightly but different characters

Hi, I've tried inserting some chinese characters into the form, convert it to utf-8 and store in the database (db2 udb v7.2) using entity (cmp) beans. Everything looks ok until when i retrieved the data from the database , it sure display chinese characters but some of them are not the characters i initially entered, can some experts please help? Thanks in advance!
Below are the code i use to convert to utf-8 and back to display in a jsp page:
Converting to utf-8
byte[] fieldByteValue = field.toString().getBytes("ISO8859_1");
String fieldStringValue = new String(fieldByteValue, "UTF8");
Converting back from utf-8
byte[] fieldByteValue = this.fields.getBytes();
String fieldStringValue = new String(fieldByteValue, "UTF8");

If you are to store a byte array of a String object encoded in UTF-8, use this form, under the condition that the String object consists of correct chinese characters:
byte[] fieldByteValue = field.toString().getBytes("UTF8");It will be retrieved to a String object in the form:
String str = new String(fieldByteValue, "UTF8")

Similar Messages

  • Not able to display data in different columns using Unicode encoding

    Hi,
    Iam using Unicode encoding in my Java appln to support Japanese characters while downloading CSV report. But using the Unicode encoding displays all data in the first column of Excel sheet.
    Please let me know how to display data in different columns using Unicode encoding in Excel sheet.

    Hi Venkat,
    After extracting data into DSO check the request whether active or not.
    Check data in DSO in contents.
    If is there any restrictions on info providers in Queries.
    Let us know status clearly.......
    Reg
    Pra

  • Display resolution is different left and right sides

    Hi, my HP G42 laptop now has a different display resolution on the left and right sides. The left half seems to have less resolution than the right side, the right side looks like it's in HD, the left side looks washed out. I'm not sure if it is a hardware issue or a setting/software issue. The first time it appeared was after a windows 7 update was completed and installed, I'm not sure if that was just a coincidence. Any suggestions would be greatly appreciated. It works but is very annoying to look at.
    Thank you,
    Ray

    Hi Ray_M,
    Welcome to the HP Forums! I see that you are having a problem with two different resolutions on each half of your screen. The easiest way to determine where the problem lies is to connect it to an external monitor. If the image is normal then we know it is an issue with the display screen but if the issue occurs on the external monitor then we know it is a problem with the drivers or the video card itself.
    What is the product number for your g42? There are a number of different models in that series.
    Please click “Accept as Solution ” if you feel my post solved your issue.
    Click the “Kudos Thumbs Up" on the right to say “Thanks” for helping!
    Thank you,
    BHK6
    I work on behalf of HP

  • My spotcolors aren't displaying correctly. (Different from the swatch)

    I am having an issue that has just randomly happened where when I want to make a colour a certain spot colour from my swatch library fill a certain shape it DOESNT CHANGE the colour yet it SAYS IT IS ANOTHER COLOUR when I do a separations preview. I'll try to explain.
    The thing is is that it works to be changed to any other colour in my swatch library than the one I want it to be changed to. And this issue is only happening to ONE swatch in particular that I have not made any alterations to, and that has always worked perfectly. If I create a new document it will display correctly, but when I paste the shape into another document that has the same exact settings and spot colours it pasts as a different colour. (like the same as Top Black 2)
    I AM HAVING DIFFICULTY WITH TOP BLACK 1 (these spot colours have not changed and I've always used them.)
    My shapes are wayyyyy too much to remake in the new document- so I have to copy and paste many layers.
    I'm sorry if this seems confusing I made up some pictures.  I am just using circles to show you my problem.
    Below is when I have made a new document from the same template I use and have always used. The spot colours from my library are seen here in their proper colours. (by the way I am not working in greyscale I still use actual colours. My document is CMYK)
    SO this happens vice versa if I paste  shape TOP BLACK 1 from an old document into a new or from a new document to an older one.
    Below You now see what I have copied from my brand new document (above) and have pasted it into my previous document and as you can see, my TOP BLACK 1 has now darkened now displaying as my Top Black 2.(or at least close to it) I CAN change the TOP BLACK 1 shape into any other colour, for example my working pink colour. But when I click it to be Top Black 1 it still stays the way it is shown here. I think you can notice that what TOP BLACK 1 is now is way darker than the Grey it's supposed to be in my library on the right. Circle 3 and 4 have correctly copied and pasted in the correct colour.
    Heres the other strange thing too. If I click and hold my TOP BLACK 1 swatch in my library (as seen above) and drag it to my main illustrator swatch library, it displays darker. The pink arrow shows the swatch that it has turned into. I am so confused of what it is doing.
    When I turn on my separations preview and turn off top black 1 all that i have that is TOP BLACK 1 disappears... so it is SEPARATING correctly its just not displaying on my screen as the correct colour.
    Let me know if there is anything else to explain. I have restarted my computer, reset launch settings etc. I only found one forum where a person has the same problem and it had a few suggestions of the appearance panel settings but none of that has worked. I have the most updated Illustrator CC
    Thankyou.

    1 appears to be the one that is off the most.
    2 is slightly off
    You may have an extra fill assigned at the group level that is overiding the fill at the Path level. Doubleclick on the word Contents in your appearance palette to get to the path level. To fix you can delete the fill at the group level, or simply ungroup  to break that attribute.
    As Larry mentioned, posting the file is the best way to get an answer to this one.
    If you cannot post the file, we will need to know what color document color mode, and the color type and values.
    You can also check this setting.

  • How to display more than 132 characters in a smartform

    Hi Experts,
    I am reading notes/text entries by calling read_text and then passing them in a variable. I want to display the notes. But even after declaring the variable as  LINE2048, it is displaying only 255characters as output length in smartform.
    My code:
    TYPES: BEGIN OF TYP_FINAL,
             PARTNER_NO      TYPE BU_PARTNER,         "Partner No.
            OBJECT_ID       TYPE CRMT_OBJECT_ID_DB,  "Object ID
            PROCESS_TYPE    TYPE CRMT_PROCESS_TYPE,  "Activity Type
           ACTUAL_NOTE     TYPE LINE2048,           "Actual Notes
           END OF TYP_FINAL.
    data : T_FINAL           TYPE STANDARD TABLE OF TYP_FINAL,
              WA_FINAL          TYPE TYP_FINAL.
    data:  v_actualnote     TYPE LINE2048.
              CALL FUNCTION 'READ_TEXT'
                EXPORTING
                 CLIENT                        = SY-MANDT
                  ID                            = C_0002
                  LANGUAGE                      = sy-langu
                  NAME                          = l_name1
                  OBJECT                        = C_BUT000
                TABLES
                  LINES                         = t_line
               EXCEPTIONS
                 ID                            = 1
                 LANGUAGE                      = 2
              IF SY-SUBRC = 0.
               clear: v_accountnote.
               LOOP AT T_LINE INTO WA_LINE.
                 CONCATENATE v_accountnote wa_line INTO v_accountnote SEPARATED BY space.
                 clear: wa_line.
               ENDLOOP.
              wa_final-account_note = v_accountnote.
              clear: v_accountnote.
             ENDIF.
    On the smartformm side, under main window->loop->text(to display the variables).
    How to display more than 255 characters in a smartform.
    Regards,
    Sangeeta.

    why the heck would you use read_text when you want to print a text/note on a form?
    in SAP-Script we use the "INCLUDE"-Statement for this.
    and in smartforms a Text-node of type 'I'.
    you can not write all in one line and expect the system to handle this like a floating text.
    one character takes a cretain amount of space (varying for different characters and font and font sizes).
    you Page has a certain width, so where is the miracle in the thesis that on a sheet of paper with a certain width just a certain amount of characters will fit?

  • ABAP Programming to display more than 255 characters in the screen

    Hi
       I want to display more than 255 characters in the screen after executing a report but i cant able to do that.
    Please help me to find out the solution.
    Thanks
      Mrutyunjaya Trpathy

    Hai tripathy,
    when the output of a report contains columns extending more than 255 characters in length.  In such cases, this set of ALV functions can help choose selected columns and arrange the different columns from a report output and also save different variants for report display. This is a very efficient tool for dynamically sorting and arranging the columns from a report output. The report output can contain upto 90 columns in the display with the wide array of display options.
    The commonly used ALV functions used for this purpose are;
    1.REUSE_ALV_VARIANT_DEFAULT_GET
    2.REUSE_ALV_VARIANT_F4
    3.REUSE_ALV_VARIANT_EXISTENCE
    4.REUSE_ALV_EVENTS_GET
    5.REUSE_ALV_COMMENTARY_WRITE
    6.REUSE_ALV_FIELDCATALOG_MERGE
    7.REUSE_ALV_LIST_DISPLAY
    8.REUSE_ALV_GRID_DISPLAY
    9.REUSE_ALV_POPUP_TO_SELECT
      hope u can try in this way.
    REGARDS,
    PRABA.

  • Menubar submenu icon display right side..

    Hi.,
             I have using menubar with  custom item renderer menus. sub menu icon was displayed right side corner. but i want to display left side icon and then labelfield., using iconfield and labelfield also.
    Any one help this problem..
    With Regards.,
    Lings

    Flex 4.1 will have support for right-to-left languages.  Is that what you
    are trying to accomplish or are you just trying to get a different look?  If
    you just want a different look, subclass MenuItemRenderer and look at past
    threads on how to apply it.

  • When using the camera downloader in Adobe Bridge CS6 with Nikon D5200 we are unable to see previews of the photos and it is very slow to download. The issue occurs under a the users rights, but not under admin level. This is a new issue

    When using the camera downloader in Adobe Bridge CS6 with Nikon D5200 we are unable to see previews of the photos and it is very slow to download. The issue occurs under a the users rights, but not under admin level. This is a new issue.

    Hi Jdentremont,
    Lync client gets user photos by first querying the Address Book Web Query (ABWQ) service on the server, which is exposed through the Distribution List Expansion web service. The client receives
    the image file and then copies it to the user's cache to avoid downloading the image each time it needs to be displayed. The attribute values returned from the query are also stored in the cached Address Book Service entry for the user. The Address Book Service
    deletes all cached images every 24 hours, which means that it can take up to 24 hours for new user images to be updated in the cache on the server.
    To troubleshoot your problem, please follow the steps below:
    1.  Navigate to
     “X:\share\1-WebServices-1\ABfiles\000000000\000000000” folder. (ABS file share)
    You should see some photo files in this folder as the following screenshot.
    2. Delete all the files in this folder.
    3. On test PC, delete local cache files.
    %userprofile%\AppData\Local\Microsoft\Office\15.0\Lync\[email protected]
    4. Sign-in Lync with the test account.
    5. Go back to the ABS file share, check if there is any Photo file in the folder.
    Best regards,
    Eric
    Please remember to mark the replies as answers if they help, and unmark the answers if they provide no help. If you have feedback for TechNet Support, contact [email protected]

  • I have a problem while typing in my MacBook pro. it is showing different characters when i type. for example: qw`e§r]t[y=   this is how when we type "qwerty|" can anyone help me pls?

    I have a problem while typing in my MacBook pro. it is showing different characters when i type. for example: qw`e§r]t[y=   this is how when we type "qwerty|" can anyone help me pls?

    You could just try changing your Input Sources under System Preferences>Language & Text:
    But I kind of doubt that's going to work. It may be a hardware problem or a system problem. If you take it into Apple they might be able to determine which and might advise a reinstallation of System software. I would take it to an Apple Store or an AASP but, first, make sure that you have a backup just in case they suggest a clean install of the system.
    Good luck,
    Clinton

  • How can I create 2 catalogues (same design but different languages)

    Hello,
    I have to launch 2 catalogues (32 pages) in Indesign, with an equal layout but different languages. My client will need to start them both and won't wait for a agreement on a Master file. He'll update the layout all along the realisation (color, pictures and graphic design).  To avoid waisting time by correcting twice, would you have a tip to link both composition and enhance automatically the background layout and ajustements over and above the languages ?
    What would be the best method ?
    Thanks a lot for your advices !
    Caro.

    Welcome to the discussions.
    In the Accounts tab of Mail's preferences, you can set the Full Name (I don't know how it will be labelled in French - it is the 3rd field in Account Information). This is the name that will be displayed in the From column of the recipient's mail client.
    But if the mail accounts are for two different users, it would be better to set up a separate login account on the mac for each of them, and then set up the mail preferences for the separate users.
    AK

  • HT204291 Using Azul media player app on my ipad  Apple tv will only display sound but not video from movies.  Any ideas on a fix.  I set mirroring to on but it still does not display video.  It will display photos and video recorded from my iphone.

    Using Azul media player app on my ipad  Apple tv will only display sound but not video from movies.  Any ideas on a fix.  I set mirroring to on but it still does not display video.  It will display photos and video recorded from my iphone.

    Here are the steps for AirPlay:
    Before starting Azul from your (running iOS 5.x/6.x) home screen where have have all your apps we need to turn on mirroring
    On your iPhone 4S/5 or iPad 2 or 3, double-click the Home  Button to view your recently-used apps.
    Swipe all the way to the right to until you see the  icon.
    Note: If the icon does not appear, go to the "If AirPlay Mirroring is not visible or available on your mobile iOS device" section.
    Tap the  icon to see the list of available AirPlay devices.
    Enable AirPlay Mirroring in this menu by tapping on an available Apple TV, then sliding the Mirroring slider to ON.
    Now you should be seeing your iPad/iPhone on your TV.
    Start up Azul now and using the settings icon on the top right corner go to the option that say "TV out" ON.
    When you do that you will see an Orange screen
    Now click "Done" and play the video you want to watch and it will AirPlay

  • Mpower max 780 lightning UEFI not displayed right and windows 8.1 no DVI-input

    Hi all,
    I’m new to the forum, I’m very sorry that my first post is the posting of a problem.
    I’ve read several treads just to be sure I’m not asking the same question twice.
    In this case I have 2 problems, both are problems more users have issues with but not as a combination of both, that’s why I posted it.
    I’ll start with my rig:
    Intel i7 4770K
    MSI Z87 Mpower Max
    MSI Geforce GTX 780 lightning
    Crucial Ballistix tactical BLT2C8G3D1608ET3LX0CEU
    Crucial 2.5" M500 480GB
    Seagate Barracuda 7200.14
    Seasonic Platinum Series 860 Watt
    Asus VG248QE monitor
    The problems
    After installing my rig myself I stated it up and everything worked fine.
    Installed windows 8.1
    Installed a few games (I couldn’t wait to try it out)
    Then after shutting down and starting up de the next day the problems started
    The bios screen wasn’t displayed right:
    - Resolution isn’t correct
    - Getting art-effects when trying to adjust a setting in the bios
    - When saving, bios is stopt working with an error message that the bin file is incorrect
     so setting up the bios is a big problem
    The second issue is that when I let it go and load windows 8.1:
    - It shows the partially BIOS image (big yellow M)
    - Then the windows logo with the loading circle
    - Followed by a black screen and my monitor telling me that there is no DVI signal
    What I’ve done so far:
    A windows 8.1 repair (so everything whipped) “fresh” install on my SSD then again install of the Nvidea driver.
    This worked for a hours of gaming funn, with 3 or 4 reboots of the system (so I thought problem fixed).
    Sadly not, I began to check the forums and found that I needed to run W8.1 in safemode to clear the Nvidea drivers en again install the latest version along with the Intel VGA drivers.
    I’ve tried that but no luck on that one.
    And yes I’ve tried to clear CMOS (several times)
    I’ve tried to flash the BIOS but I can’t select my USB drive when I press F11 (so I’ll be trying another USB stick soon)
    Getting the bootsequence to boot from USB isn’t an option also because of the bios screen issue.
    Does anyone have the same issues, or even better does anyone have a solution to all my troubles?
    Thanx,
    Quasi

    Quote from: flobelix on 22-November-13, 02:03:09
    Ok it is in legacy mode then. Waiting for your report. If it comes up on the igpu also check the bios version. Would be better than guessing.
    Oke tested the HDMI cable, after starting up finally i got a normal BIOS view again.
    BIOS Version E7815IMS V1.2 (so it's 1.2 instead of 1.0) so much for guessing...
    As expected windows started normally in high resolution.
    So i think the problem is that the MB bios doesn't work wel with the videocard or the videocard is DOA.
    any thoughts for the next step?

  • Display not working, external display does, but blue screen when windows loads

    Hi folks, wondering if anyone can help.
    My DV6's display is no longer working.  An external VGA display works, but when it gets to the "welcome" screen as it loads into windows, I get a blue screen.  I was able to load into safe mode previously, but I foolishly reformatted and reinstalled windows thinking it might solve the problem.  Now I can't even get into safe mode because it won't allow a first time setup of Windows in safe mode.
    I suspect this may be the death of my loyal notebook, but was hoping someone could propose a solution.
    Thanks!

    HI @Mikep037,
    Thank you for your query, I am happy to assist you!
    I understand that you are having an issue with your display.
    You have reformatted and reinstalled Windows but are unable to complete the setup.
    Did you do a recovery or did you reinstall Windows from a retail disk?
    First I would try a hard reset.  HP Notebook PCs - Use Hard Reset to Resolve Hardware and Software Issues.  Please be sure to remove any CD/DVD from tray and disconnect all externals devices or USB's.
    HP Notebook PCs - Overview of How to Troubleshoot Problems When a Computer Does Not Start Up or Boot...
    Here links to aid with the recovery process.
    HP PCs - Performing an HP system recovery (Windows 7)
    HP Notebook PCs - System Recovery May Fail or Display Error Message (Windows 7, or Vista)
    Best of Luck!
    Sparkles1
    I work on behalf of HP
    Please click “Accept as Solution ” if you feel my post solved your issue, it will help others find the solution.
    Click the “Kudos, Thumbs Up" on the bottom right to say “Thanks” for helping!

  • PowerMac G5 & Display starts but after the grey Apple logo screen dies

    When I turn on my PowerMac G5 it turns on OK along with the LCD display. But once the Apple logo and the spinning gear shows up (by the way the gear gets all pixelated and turns blue) the LCD display suddenly goes black as if it goes to sleep. The PowerMac is still running though but it's not responsive. I even tried opening the DVD drive with the keyboard and nothing happens. I took someone's advice of rebooting in Safe Mode and everything works OK for now. When I try rebooting in normal mode the problem persists.
    What could be the problem? Is this a hardware issue? I even tried with another display and same thing happens.
    Sad thing is my 3 yr. Apple Care expired a few months ago, never ever used it.

    Second time I've heard of display problems and 10.5.5., but it might be coincidental. For the other poster starting up in safe mode also helped but didn't cure his problem. Maybe taking out and reinstalling the video card would bring your mac back to its senses again.
    http://www.info.apple.com/usen/cip/pdf/g5/073-0808.pdf
    I was looking for some display preference to be trashed but there were so darn many of them I couldn't figure out what the right one might be. In case I missed it, have you tried resetting your PRAM?

  • I can't connect my mac to my TV, I have the right cables and have done it right but I still doesn't get the macscreen on the Tv, what should I do?

    I can't connect my mac to my TV, I have the right cables and have done it right but I still doesn't get the macscreen on the Tv, what should I do?

    What are you getting on the TV?  Are you getting a completely blank screen, or are you getting a message similar to 'no input detected'?  Or are you seeing the spiral galaxy desktop?  If you go into System Preferences -> Displays then do you have an 'Arrangements' tab?

Maybe you are looking for

  • Why doesn't the Wi-Fi work on my IPod

    My IPod is connected to my wifi but it doesn't actually work.

  • Clear difference

    hi, i need to know the difference below. hope can reply by point. 1) what is the difference for fb05 (post with clearing) VS f-03 (clear gl) , f-32(clear cust), f-44 (clear vendor). i mean all also clear so what is the difference? 2) under what circu

  • BW Info Object update problem

    Hi All, We are implementing BW. The Vendor and Document date info objects are not mapped directly to SAP R/3. Hence the data is not updating directly fromR/3 for these info objects. So I have written a small transfer routine to update the info object

  • Verizon Turbo Dsl plan with Westell 6100 modem? Help?

    So I have a westell 6100 modem and on the 7th I upgraded my bundle i had 1 Mbps for Internet , verizon homephone freedom essentials, and Directv. Since fios is not available were I live. And my new bundle is Verizon Dsl 7.0-1 Mbps turbo plan, verizon

  • Error when calling inbound proxy

    Hi all, I´m facing the following problem in the R/3 monitoring: <SAP:Code p1="Request Message" p2="CX_XSLT_RUNTIME_ERROR" p3="/1SAI/XS00000000000000000035: 0000000000" p4="Error Text: No valid source context supplied Kernel ErrorId: CX_XSLT_RUNTIME_E