Results 1 to 2 of 2
  1. #1
    Join Date
    Jan 2005

    Unanswered: How to convert newline/return carriage character

    I am migrating data from an Oracle 8 databse to a DB2 database. The steps I am following are

    1. Importing data into an excel sheet.
    2. Rearranging the columns according to my current database design which is more or less similar
    3. Then saving the excel file as a comma separated file .csv
    4 Finally I import the data into DB2 using the import command.

    The problem I am facing is that the current data in Oracle has some new line chars which appear like small rectangles in the dbase but when exported in to csv make the text go on to the nextline,
    so data which is like this " Johna|than" in the oracle database appears as


    because of which I get errors while importing data....

    Any ideas how do I solve this problem ????

  2. #2
    Join Date
    Jan 2004
    If the data in the database has carriage return, try doing a replace chr(10) or chr(13) -

    so something like:
    select replace(line_feed_col, chr(10),'')
    from your_table
    If chr(10) does not work use chr(13) - I honestly forget which one is which.
    Oracle OCPI (Certified Practicing Idiot)

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts