I'm using Access 2007. Here's a file name that won't import:
2007_accelrys_ROW-REGION_AllSites_AllLocales_Monthly_Jul_Detail.csv
Even using the import wizard, it tells me it cannot find the object
2007_accelrys_ROW-REGION_AllSites_AllLocales_Monthly_Jul_Detail.
(truncates
the last 3 characters csv). Using the wizard, I'm browsing my way to this
file. This leads me to believe there must be a limitation of 64
characters
I thought the limit was 255 and I have no trouble using an
80+ character file name.
Is there any chance that the file name contains an
apostrophe?
--
Marsh
MVP [MS Access]
Kirk P. wrote:
I think I've found the problem. It appears there is a 64 character
limit on
file name length. I don't know if that's an Access limitation, or a
limitation of the DIR function. The data from the file is never
imported,
therefore (obviously) the SQL doesn't work.
So the next question - is there any way around this 64 character limit
on
file names (other than shorten the length of the file name, which is
beyond
my control)?
Kirk P. wrote:
I've got code to build a SQL string programatically. I'm getting a
3125: Not
a valid name error on this line:
strSQL = "UPDATE tblPAC_PEN_DETAIL SET FileName = '" & strFileName &
"'
WHERE FileName Is Null;"
strFileName is built with this line: strFileName = Dir$(strPath &
"*_Detail.csv")