Any way to export a file with the entire contents of a memo field?

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

I created an Access table so I could use a form to fill in the information
that changes for each record and use defaults for a lot of fields that don't
change. The table is then to be exported to CSV for use in a non-MS
application. So far, so good, except I need to have one text field much
larger than 255. If I configure it as a memo field only the first part of
the text is exported in its proper place in the record...the rest of the text
sort of trails in at the end of the record messing up everything. Any
suggestions? Thanks in advance.
 
This sounds more like a problem with the software that you're using to
import or view the exported file.

At the Access end, if you have line breaks in your data (as I presume
you do in your long memo fields), all you have to do is make sure to
export the data with the following settings in the export wizard:
Delimiter = , [comma]
Text qualifier = "
If you open the exported file in Notepad or another text editor, you
will see that the memo field is exported in its correct place.
 
You are absolutely right. The only wrinkle is that the program into which I
am importing the data doesn't like quotations around the field titles in the
first row. When I opened the file in a text editor and manually deleted the
quotation marks around the field titles. It imported perfectly then. That's
the good news. The bad news is that there are a *lot* of fields!
 
You are absolutely right. The only wrinkle is that the program into which I
am importing the data doesn't like quotations around the field titles in the
first row. When I opened the file in a text editor and manually deleted the
quotation marks around the field titles. It imported perfectly then. That's
the good news. The bad news is that there are a *lot* of fields!

Just use find-and-replace to find all the quote marks in the first line
and replace them with nothing. Or if Perl is installed on your computer,
open a command window and use
perl -i.bak -pe "s/\x22//g if $. == 1;" "D:\Folder\file.txt"
 
Thanks... I found I could put three quotation marks (""") around the text in
the memo field and export the file without quotation marks. This doesn't
mess up the headings in the import program, but leaves the quotation marks
around the text only.
 
Hi Auntpat,

Your trick seems just like what I'm looking for, but I don't understand
exactly where you put those quotation marks and why you used this trick.

I know you've put your question here ages ago, but I just give it a try... :-)

Bye!
Sietske
 
Back
Top