Comma-delimited file

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

Guest

I have created a comma delimited file from MS Project using OLE DB connection
to Access. The problem that I am having is when I use the transfertext action
to create the Access table I get a couple of blank rows. I noticed in the
flat file that at the end of the file I have a couple of blank rows as well.
I use the vbcrLf to go the next line after I create each record.

Is there a way to remove the blank lines before importing the file into
Access?

Thanks.
 
In WD typed:
I have created a comma delimited file from MS Project
using OLE DB
connection to Access. The problem that I am having is when
I use the
transfertext action to create the Access table I get a
couple of
blank rows. I noticed in the flat file that at the end of
the file I
have a couple of blank rows as well. I use the vbcrLf to
go the next
line after I create each record.

Is there a way to remove the blank lines before importing
the file
into Access?

Thanks.

It might be easier, though perhaps less elegant, to run a
delete query on the resultant table to remove the blanks.

--
Nick Coe (UK)
AccHelp v1.01 Access Application Help File Builder
http://www.alphacos.co.uk/
Download Free Copy
----
 
If Perl is installed on your system, you can delete the blank lines from
a textfile by running this command (substituting the location of your
file):

perl -i.bak -ne"print if m/./" "D:\folder\filename.txt"
 
WD said:
I have created a comma delimited file from MS Project using OLE DB
connection to Access. The problem that I am having is when I use the
transfertext action to create the Access table I get a couple of
blank rows. I noticed in the flat file that at the end of the file I
have a couple of blank rows as well. I use the vbcrLf to go the next
line after I create each record.

Is there a way to remove the blank lines before importing the file
into Access?

Yet another alternative would be to link to the file instead of
importing it, then run a make-table query that selects only the
non-blank records (which presumably would have Nulls in the various
fields) and puts them into your output table, then delete the linked
table.
 
Back
Top