Consulting

Results 1 to 3 of 3

Thread: save file as CSV

  1. #1
    Moderator VBAX Master austenr's Avatar
    Joined
    Sep 2004
    Location
    Maine
    Posts
    2,033
    Location

    Talking save file as CSV

    Hi all,

    I need to save the attached as a CSV file with the fields enclosed in " ", fields terminated by ";" in ascii format. I need to import this into a mySQL table. The part that throws me is that the first field has ; in the field description which needs to stay there (I think it looks bad).

    So if you import it as fields terminated by ; then i will end up with bogus data. Any suggestions appreciated.

  2. #2
    Knowledge Base Approver VBAX Master Oorang's Avatar
    Joined
    Jan 2007
    Posts
    1,135
    Location
    If you cannot change your import spec, then personally I would replace all occurances ";" with something unlikely such as ":::" (or something else) before I saved to csv. Then I would import my data and just run an update query to change ":::" back to ";".
    Cordially,
    Aaron



    Keep Our Board Clean!
    • Please Mark your thread "Solved" if you get an acceptable response (under thread tools).
    • Enclose your code in VBA tags then it will be formatted as per the VBIDE to improve readability.

  3. #3
    Moderator VBAX Master austenr's Avatar
    Joined
    Sep 2004
    Location
    Maine
    Posts
    2,033
    Location
    Good idea, hadn't thought of that

Posting Permissions

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