Replacing german charcters with ?

Hi,
I have been having this problem for past few days where the characters are getting replaced with ?
for eg this text is getting replaced with Stra�e Stra?e, when i run the program as a Standalone using java command it outputs correctly on a linux box but when it is run as a cron on the same linux box it replaces the character with a ?.
I have seen a similar thread on the same topic earlier but trying out the solutions out there havent helped.
Please help
Thanks In Advance
Someone in distress

can't reproduce your problem... running fedora core 4 with sun jdk 1.5.0_04
java code:import java.io.*;
import java.util.*;
public class cron {
    public static void main(String[] args) throws Exception {
     ByteArrayOutputStream out = new ByteArrayOutputStream();
     String str = "stra\u00dfe"; // �
     byte[] strbytes = str.getBytes("ISO-8859-1");
     out.write(strbytes);
     byte[] outbytes = out.toByteArray();
     if (outbytes[4] != (byte) 0xdf)
          throw new Exception("error converting");
     System.out.println(new Date() + " " + str);
}helper script for cron:#!/bin/bash
cd ~joni/Desktop
java -Dfile.encoding=UTF-8 cron 2>&1 > cronout crontab:$ crontab -l
* * * * * /home/joni/Desktop/jcronjoboutput: cronout file on desktop contains the the current date and the word stra�e, encoded in utf-8
From where do you read the data?

Similar Messages

  • I replaced my iPhone with a Galaxy 5 and am not receiving all of my text messages. The sales person told me to remove my phone number from iTunes to stop this from happening. Is that true? What does iTunes have to do with text messages?

    I replaced my iPhone with a Samsung Galaxy5 and I am not receiving all of my text messages now. The rep at the store told me to go to iTunes and take my phone # off of the account and that would fix the problem. Is that true? What does iTunes have to do with text messages anyway?

    You need to remove your phone number from the iMessage system.
    Read here: http://support.apple.com/kb/ts5185
    ~Lyssa

  • Ever since Firefox 3, I have never been able to upgrade easily. I always get a message telling me I am replacing my version with an older version. How is that possible?

    When I download the newest version (this time it was 5, but I had the same problem with 4) and I drag the Firefox Logo to my Applications folder in Mac OSX (10.6.7) I get a message saying I am replacing my version with an OLDER VERSION. How can this be? When I check the Firefox "About" tab, it tells me I am still using 4, so how, if I just dragged 5 to my Applications folder, can I be replacing 4 with an "older" version? Truth be told, my Firefox has never functioned properly since 4, and now I have little "Firefox hard drive icons" all over my desktop. What happened?
    I am having trouble with Comcast's XFINITY and they told me to update and maximize my browser. I don't seem to be able to do that. I just downloaded Firefox 5.0, but my version still says 4.1.

    When I download the newest version (this time it was 5, but I had the same problem with 4) and I drag the Firefox Logo to my Applications folder in Mac OSX (10.6.7) I get a message saying I am replacing my version with an OLDER VERSION. How can this be? When I check the Firefox "About" tab, it tells me I am still using 4, so how, if I just dragged 5 to my Applications folder, can I be replacing 4 with an "older" version? Truth be told, my Firefox has never functioned properly since 4, and now I have little "Firefox hard drive icons" all over my desktop. What happened?
    I am having trouble with Comcast's XFINITY and they told me to update and maximize my browser. I don't seem to be able to do that. I just downloaded Firefox 5.0, but my version still says 4.1.

  • I created my Apple ID in Ireland, but would now like to switch to a German Apple ID, keeping the same email address. How do I delete my old Irish Apple ID, so I can create a new German one with the same email?

    I created my Apple ID in Ireland, but would now like to switch to a German Apple ID, keeping the same email address. How do I delete my old Irish Apple ID, so I can create a new German one with the same email?

    Welcome to the Apple Community.
    Click on your account name in the top right corner of the iTunes store in the iTunes application on your computer, enter your password and click the "view account" button. Navigate to the Apple ID summary where you have the option to "change country or region".
    In order to change your location, you will need a credit card registered to an address in the location you are trying to change to.
    You cannot change your location if you have credit on your account, if you are unable to spend your credit and leave a balance of zero, contact Apple, which you can do through iTunes Store Support.

  • How to replace one variable with another in large number of queries

    Hello guys!
    I have this situation: our company needs to use one variable instead of another for certain amount of queries.
    Is there some way to automatically replace one variable with another for a certain characteristic in big number of queries ( like 150 - 200 ) ? Doing this manually would take lots of time)
    Apreciate your help!

    you could try (at your own risk) the following:
    1. search the technical id (ELTUID) of your variable in table RSZELTDIR
    2. see where this variable is used in table RSZELTXREF (by filling RSZELTDIR-ELTUIID in RSZELTXREF-TELTUID)
    3. add similar entries for your new variable
    4. delete the entries for the old variable (they're part of the key, so you can't simply "change" them)

  • I can't find the tutorial on replacing a person with another image from a different photo.

    I got an email with a link to a video a long time ago that showed how to remove a person from a group photo and replace this person with an image of them from another photo.  It does not seem to be in the videos on my Phtotshop elements 9 list within the program.  Does anyone have a link to this video so I can save it and rewatch it?  Thanks

      Click on the link below and go to: Easily Create the Perfect Photo
    It’s designed for several people but it should work with just one person in the shot. After viewing the tutorial open both images in Full Edit and go to:
    File >> New >> Photomerge Group Shot
    http://www.adobe.com/products/photoshop-premiere-elements/features.edu.html?promoid=GYSZM

  • My one year warranty expired recently, a month ago my charger was replaced under warranty and it has only lasted a month and has broken again, does the replacement charger come with a new warranty or will i have to buy a new one?

    Bought the phone on contract last January (late in january), had my charger replaced just after christmas and now it has stopped working again, its been about a month and a half and the replacement charger is broken, does the replacement charger come with a new warranty or will I have to buy a new charger? And if so, is there a charger that doesn't break easily (my problem is the the wire at the phone end of the cable seems to bunch and twist etc.)
    thanks.

    a warranty replacement if the donor is out of warranty has a new 90 days warranty from exchange date 

  • Replacement Path Variable with Another Variable

    Hi,
    I am currently trying to create a report that would need me to have the same values for different characteristics (e.g. clearing date, posting date, net due date). I have seen that there is a way in the replacement path variable that would replace its value with another variable that is ready for input. I also looked into SAP help but I can't seem to figure out on how to do it specifically. Does anyone know a step-by-step process on how to do this? How does this work?
    Thank you in advance!

    take an e.g.
    u have characteristic say ch1
    u want to restrict it with replacement path variable
    first of all create a variable var1
    click what it is based upon for e.g. 0calday, 0material etc.
    make it user entry variable
    select single or multiple entry
    make it mandatory
    save it and hit okey
    click on ch1
    right click and say restrict
    in new window create a new variable
    give its name and technical name
    processing path is replacement path
    go to next tab of replacement path
    select several ooptions
    replace variable with another variable
    select a variable called var1
    change the offset length and offset start with different parameters.
    hit okey
    this way u have restricted ch1 with replacement path variable var1
    now when u run report u have to enter value of var1
    which will then further feeded to ch1
    this way u can create replacement path variables at lots of instances and then u can always feed the value from var1 at different time
    make sure as this ur requirement is date
    try to use 0calday as reference infoobject all the times....

  • How do i replace my ipad with a new model in itunes?

    I'm replacing an iPad with an iPad 3rd generation and will be gifting the iPad to a friend.
    What steps do I need to take in iTunes for this to run smoothly?
    I want to end up with:
    1) The new iPad working but with all of my data, screen layouts and settings from my old iPad.
    2) The old iPad "de-registered" (if that's possible/necessary) and reset to factory default conditions with no data present and working on myfriends iTunes account.
    Is 1) as simple as backing up the original iPad in iTunes and plugging the new one in and restoring from the old backup? Possible complication: I get the "This iPad is synced with another computer. Do you want to erase and restore..." message whenerver I plug it in, although it does seem to sync when I cancel the "erase and restore" dialog. Would this complicate things?
    Re 2), my friend has an iPhone 4 and uses iTunes already. Is plugging in my "wiped" iPad all he needs to do? How do I reset the original iPad?
    I hope that these are simple questions, already encountered by many of you, but myself and my friend are at the stage where we have both only had one apple product and have never had to manage another device in iTunes so we just don't know what to expect and don't want to lose any data!
    Thanks in advance for your time and help!

    Is it as simple as backing up the original iPad in iTunes and plugging the new one in and restoring from the old backup?
    Yes
    How do I reset the original iPad?
    Settings --> General --> Reset --> erase all content and settings;.

  • Since i got the new Iphone 4s it constantly drops calls. Apple have replaced the phone with another new iphone 4s but i am still having the same problem. I have checked with vodapohe that there is no issue from there end, given a new sim, still drops out

    Since i got the new Iphone 4s it constantly drops calls. Apple have replaced the phone with another new iphone 4s but i am still having the same problem. I have checked with vodapohe that there is no issue from there end, given a new sim, still drops out

    Have a look at this it might help
    http://support.apple.com/kb/TS4148

  • Do I have all the parts to replace my HDD with a new SSD on my Macbook (late 2008)?

    Hey everyone, I am trying to figure out if have all the parts to replace my hdd with a new ssd on my macbook (late 2008 aluminum).
    I just bought a crucial mx100 SSD and plan on replacing my mac HDD. I have the appropriate screwdrivers, and a bootable OSX on a usb drive. I also purchased a sabrent usb 2.0 to sata/ide hard drive adapter.
    How do I replace and install OSX on my new SSD?
    From what I read here are the steps I'm planning on taking.
    1) Detach the old HDD
    2) Attach new SSD.
    3) Turn on computer and use the bootable usb drive to install OS X.
    Does that work, I think I read somewhere about maybe formatting the SSD before I can use the bootable usb. Any input or help would be awesome. Thanks.
    I'd prefer to do a clean install of yosemite and not carbon copy my old HDD

    Hi Bradtk24,
    On this site you will find the requirements for the physical change that you want to make.
    These pages will give you insight into the processes required for the software side of things. It might be slightly dated, but the principles remain valid.
    Have fun
    Leo

  • Want to replace stock HDD with a 256GB SSD, have questions.

    Hi All,
    I am sure this has been asked a bunch of times, so forgive me if I ask again...
    I have a late 2010 MBP (Model A1278).  Currently the machine has 4gb of memory and a 256gb hard drive on it.  The machine is starting to show its age and is slowing down considerably, so I was thinking of upgrading the memory to the max allowable 8gb, and swapping out the HDD with a nice 256gb SSD.  What I am looking to find out is if I have daily time machine backups, can I just swap out the drives, reboot the machine into recovery mode and then select a TM backup to restore to this new drive?
    My main concern with all of this is that I have been reading stories of people having to first create a partition on the SSD, then transferring over the TM backup, but I am not sure how I would set a partition when the drive itself is internal... Do I need to get an enclosure?  Is there some other easy way to accomplish this?  Is it even necessary?
    My ultimate goal is this:
    1. Open laptop
    2. Replace memory
    3. Replace hard drive with SSD
    4. close laptop
    5. Boot Laptop into recovery mode (Command + R)
    6. Restore from Time Machine Backup
    7. Select backup date
    8. Restore finished.
    9. Reboot Laptop into normal boot mode
    10. Enjoy a slightly faster laptop 
    Thank all!!!

    Unless you purchase your SSD from OWC your drive will have to be partitioned first. The OWC SSDs I've bought have already been partitioned and formatted for the Mac. Either way, unless you have another boot drive, you'll have to boot your computer with Internet recovery since you won't have a recovery partition until you've install the operating system. Here's how I've swapped out my hard drives for SSDs
    place the SSD in an enclosure
    I've always had an enclosure or bought one when I got the SSD so I could make the old internal drive into an external drive.
    I typically use this new external drive as a clone backup for my computer
    run Disk Utility to partition the drive
    The trick is to delete the current single partition
    Then click on the + symbol to make a new partition (GUID)
    Format the drive
    Download and install OS XThis will create the recovery partition
    Swap out the SSD for the old HHD and reboot
    While the computer boots put the old HHD in the external enclosure and plug it into the computer
    Go thru the new owner setup and when asked if you want to setup the new computer say yes and choose the external as the sourceYou could also use the TimeMachine backup as your source but I find this is a bit slower than using the external drive
    Depending on what software you have you may need to enter some serial numbers.

  • I have a Mac book pro with regular drive, I want to replace the drive with SSD, so can I do t for Mac book pro purchased in 2012 and which SSD is recommended. I am looking for 500 to 700GB SSD.

    I have a Mac book pro(13 inch non-retina, i7) with regular drive, I want to replace the drive with SSD, so can I do it for Mac book pro purchased in 2012 and which SSD is recommended.
    I am looking for 500 to 700GB SSD.
    Thanks

    Upgrading your MacBook Pro with a Solid State Drive...
    ...call back with any questions.
    Clinton

  • Text file - replace a pattern with part of the previous line? -SOLVED

    Hello, I'm stuck with sed/awk/grep...
    So I have a file with lines like this:
    Nice bunch of words <STUFF> <STUFF> <IMPORTANT_DELIMITER_TYPE_1> <STUFF> <IMPORTANT_DELIMITER_TYPE_2> <STUFF>
    Even Nicer bunch of Words <STUFF> <IMPORTANT_DELIMITER_TYPE_1> <STUFF> <STUFF> <STUFF>
    Wonderful bunch of Words <STUFF> <STUFF> <STUFF><IMPORTANT_DELIMITER_TYPE_1><STUFF>
    Then, I want to move the "important delimiters" to new lines (might be better not to do this in fact...)
    Nice bunch of words <STUFF> <STUFF>
    <IMPORTANT_DELIMITER_TYPE_1> <STUFF>
    <IMPORTANT_DELIMITER_TYPE_2> <STUFF>
    Even Nicer bunch of Words <STUFF>
    <IMPORTANT_DELIMITER_TYPE_1> <STUFF> <STUFF> <STUFF>
    Wonderful bunch of Words <STUFF> <STUFF> <STUFF>
    <IMPORTANT_DELIMITER_TYPE_1><STUFF>
    And finally, I want to replace the important delimiters with the content of the line they came from originally, up to the first angle bracket:
    Nice bunch of words <STUFF> <STUFF>
    Nice bunch of words <STUFF>
    Nice bunch of words <STUFF>
    Even Nicer bunch of Words <STUFF>
    Even Nicer bunch of Words <STUFF> <STUFF> <STUFF>
    Wonderful bunch of Words <STUFF> <STUFF> <STUFF>
    Wonderful bunch of Words<STUFF>
    How can I accomplish this using absolutely anything at all that doesn't involve too much manual effort (the file is about 30,000 lines of this stuff)
    Thanks !
    Last edited by darkbeanies (2013-09-01 19:18:29)

    "<STUFF>" is not irrelevant. In your original example
    Nice bunch of words <STUFF> <STUFF> <IMPORTANT_DELIMITER_TYPE_1> <STUFF> <IMPORTANT_DELIMITER_TYPE_2> <STUFF>
    Even Nicer bunch of Words <STUFF> <IMPORTANT_DELIMITER_TYPE_1> <STUFF> <STUFF> <STUFF>
    Wonderful bunch of Words <STUFF> <STUFF> <STUFF><IMPORTANT_DELIMITER_TYPE_1><STUFF>
    you want to break the lines along the delimiters:
    Nice bunch of words <STUFF> <STUFF>
    <IMPORTANT_DELIMITER_TYPE_1> <STUFF>
    <IMPORTANT_DELIMITER_TYPE_2> <STUFF>
    Even Nicer bunch of Words <STUFF>
    <IMPORTANT_DELIMITER_TYPE_1> <STUFF> <STUFF> <STUFF>
    Wonderful bunch of Words <STUFF> <STUFF> <STUFF>
    <IMPORTANT_DELIMITER_TYPE_1><STUFF>
    and then you say that you want to replace the delimiters with the contents before the first angle bracket:
    Nice bunch of words <STUFF> <STUFF>
    Nice bunch of words <STUFF>
    Nice bunch of words <STUFF>
    Even Nicer bunch of Words <STUFF>
    Even Nicer bunch of Words <STUFF> <STUFF> <STUFF>
    Wonderful bunch of Words <STUFF> <STUFF> <STUFF>
    Wonderful bunch of Words<STUFF>
    but you have clearly made a distinction between the "nice bunch of words" and "<STUFF>", otherwise the output would have been
    Nice bunch of words <STUFF> <STUFF>
    Nice bunch of words <STUFF> <STUFF> <STUFF>
    So, do you want everything up to  the first delimiter, or do you want everything up to <STUFF> in the replacement? If you only want the "nicer words" then you need some way to distinguish between them and "stuff" programmatically.
    edit
    Here's a trivial script that will split the lines along the delimiters and replace them with the contents of the line before the first delimiter:
    #!/usr/bin/env python3
    import re
    import sys
    def main(args=None):
    for line in sys.stdin:
    # Trim trailing newline.
    line = line.rstrip('\n')
    # Split by delimiters.
    parts = re.split(r'<[^>]+>', line)
    print(parts[0])
    for p in parts[1:]:
    print(parts[0] + p)
    if __name__ == '__main__':
    try:
    main()
    except (KeyboardInterrupt, BrokenPipeError):
    pass
    Usage
    path/to/script < /path/to/input file
    Last edited by Xyne (2013-09-01 18:34:55)

  • Replace FM GUI_DOWNLOAD with CL_GUI_FRONTEND_SERVICES= GUI_DOWNLOAD

    Hi,
    I want to replace FM GUI_DOWNLOAD with CL_GUI_FRONTEND_SERVICES=>GUI_DOWNLOAD in one of our old program, however parameter FIELDNAMES is used, and this parameter is no longer available in CL_GUI_FRONTEND_SERVICES.
    Any idea is there any other parameter for this? HEADER might be, but I don't think so, as it has a different purpose in FM 'GUI_DOWNLOAD' also.
    Thanks in advance,
    Peter

    Hi Peter
       One work around will be to use the method twice,
    first to download the header to file and then in append
    mode to download the data.
    Kind Regards
    Eswar
    Message was edited by: Eswar Rao  Boddeti

Maybe you are looking for

  • How can I resolve the issues connecting to my wireless connection with my Apple tv?

         Ive had my Apple tv for about a month now & I still have not even used it for what I actually got it for. It allows me to use the airplay feature with my ipad2. But when I try to use the home sharing feature it never connects with my apple ID. A

  • Email links in an interactive report

    Hi Is it possible to have email links in an interactive report? i.e display something like "[email protected]" as a clickable link that invokes the default external email program with the "To:" field populated? Thanks!

  • Starting HTTP server via OEM

    win2000 When I try to start the HTTP server via the OEM, I get the following error message : "Preferred Credentials has not been set" where do I set it? thnx Endre

  • How to install Simple Finance Apps for SAP Fiori?

    My system: 1. ERP 6.0 EHP 7 2. Netweaver Gateway installed 3. HANA db on different machine What I have done: 1. I installed the add-on that I got from SMP. The apps seem to be present on the server side. 2. I added the necessary roles to my user so t

  • Bussiness Content Installtion Problum

    Dear Friends, I have installed Bussiness Content In BI 7. 0. But all the Tranformations are not installed. Shall i know any one waht is the problum. this is more  helpful for me. Thanks & Regards Ramana