Export - Import Issues with 'special temperamental characters'

  • Goal: to export from MS SQL to tmp file then import content into mysql 5

    I'm confused:

    - I exported MS SQL tables to EXCEL .xls

    - I have an .xls file that can be exported as a csv

    - PROBLEM: inside the content are many fields that might have single quotes - double quotes commas etc. in the content

    - this will be bad when I create a .csv because there might be some extra commas in the records - which will mess with the import

    - I can't see a way to create the CSV and use a unique character like a PIPE instead of the comma - is there a pref somewhere to choose this?

    - in the past - to export and import - I have replaced all 'tempermental characters' with special codes that are safe - then export/import , then convert them back - (that's a lot of work as many know)...

    Q: What's the best way to move text content from one database to another (with all these special characters)

  • Hi,

    If you would like to delimit your export with a pipe instead of a coma, try this:

    1. In the export data wizard, select flat file destination

    2. When it comes to the configuration step, choose '|' instead of coma

    I don't think excel will be able to read the resulting file in a sensible way. Also, using a pipe instead of a coma probably disqualifies the resulting file as CSV?

    I'm not sure how MySQL's import works, but perhaps you'd be able to set the delimeter to pipe too and import that way from a .txt file?

Viewing 2 posts - 1 through 1 (of 1 total)

You must be logged in to reply to this topic. Login to reply