Importing huge text files into Access

  • Thread starter Thread starter Steve
  • Start date Start date
S

Steve

I have a problem where I am trying to import a very large
text file (6 GB) into Access. I know that there is a 2
GB limit for the DB size, but I am not pulling in all of
the fields of this big file and the net result is less
than 2 GB (I know because I have to resort to breaking up
the big text file into smaller pieces and importing them
in separately and combining them and it fits fine in the
end). Every time I try to import the entire file, before
I even get to the part where I tell Access what fields I
want to bring in, I get a "bad file name" error message.
Is there any way to get Access to allow me to bring in
the components of this file I need or do I have to just
keep having it broken up first?
 
Hi Steve,

6GB is big by any standards and the simplest approach is to reduce the
size of the textfile before you import it. If you just want certain
fields, download the Windows version of the Gnu textutils from
http://unxutils.sourceforge.net/ and use the "cut" utility. The command
line for a fixed-width file will be something like this:

cut -c1-80,2223-2550 D:\folder\file.txt > D:\folder\new.txt

(use -f for a simple delimited file).

If it's a delimited file whose text fields are quoted so they can
contain delimiter characters or linebreaks things get a bit more
complicated: post back if you have trouble.
 
Thanks John! I'll give this a try. Thank you for your
assistance!

-----Original Message-----
Hi Steve,

6GB is big by any standards and the simplest approach is to reduce the
size of the textfile before you import it. If you just want certain
fields, download the Windows version of the Gnu textutils from
http://unxutils.sourceforge.net/ and use the "cut" utility. The command
line for a fixed-width file will be something like this:

cut -c1-80,2223-2550 D:\folder\file.txt > D:\folder\new.txt

(use -f for a simple delimited file).

If it's a delimited file whose text fields are quoted so they can
contain delimiter characters or linebreaks things get a bit more
complicated: post back if you have trouble.




I have a problem where I am trying to import a very large
text file (6 GB) into Access. I know that there is a 2
GB limit for the DB size, but I am not pulling in all of
the fields of this big file and the net result is less
than 2 GB (I know because I have to resort to breaking up
the big text file into smaller pieces and importing them
in separately and combining them and it fits fine in the
end). Every time I try to import the entire file, before
I even get to the part where I tell Access what fields I
want to bring in, I get a "bad file name" error message.
Is there any way to get Access to allow me to bring in
the components of this file I need or do I have to just
keep having it broken up first?

--
John Nurick [Microsoft Access MVP]

Please respond in the newgroup and not by email.
.
 
Back
Top