Results 1 to 4 of 4
  1. #1
    crowegreg is offline Competent Performer
    Windows 7 64bit Access 2010 32bit
    Join Date
    May 2011
    Posts
    398

    guidelines for name of csv file name


    When importing a csv file into Access 2010, what are the guidlines for the file name? number of characters, special characters within name

  2. #2
    ItsMe's Avatar
    ItsMe is offline Sometimes Helpful
    Windows 7 64bit Access 2010 32bit
    Join Date
    Aug 2013
    Posts
    7,862
    Certain media that may store the file could have some restrictions that may not apply to, say, Access 2003 with XP. In other words, HDD's formatted with NTFS compared to older formats of the FAT16 and FAT32 flavors may encounter file name conflicts. That aside, I would consider characters that would goof up a string variable. So with some clever concatanation you could probably include a few special characters in the file name. I think you can include dots in file names if enclosed in parenthesssis, in the name. Don't recall what character count limits are.

    If you predict conflicts you could create a SHELL object and call on some functions to copy and paste your CSV files so they have a different name before importing. Loop through a specified directory and locate all .csv files, copying, pasting, and killing as you go.

  3. #3
    ssanfu is offline Master of Nothing
    Windows XP Access 2000
    Join Date
    Sep 2010
    Location
    Anchorage, Alaska, USA
    Posts
    9,664
    I do not use special characters except the underscore and sometimes a space. (spaces in names are always a problem)

    I try to keep the file name portion descriptive but short.
    Here is an example: Adds_ABA_Hours1210.csv


    The number of characters is controlled by Windows. Depending on where you look, the max length is between 199 and 257 characters.
    (for your reading pleasure: http://stackoverflow.com/questions/2...-windows-vista

    Personally, I would try and keep the file name length less than 30.

  4. #4
    crowegreg is offline Competent Performer
    Windows 7 64bit Access 2010 32bit
    Join Date
    May 2011
    Posts
    398
    Thanks for both of your suggestions.

    The csv file I'm importing is system generated, with a system generated name. The name includes everything, alpha characters, numeric characters, and special characters. The import was failing due to a "(##)" within the name. I deleted the "(" & ")" and it imported correctly.

    In writing VBA, I've decided to make a copy of the file with a very simple name, import the simple named file, then delete the simple named file.

    Thanks again for your assistance.

Please reply to this thread with any new information or opinions.

Similar Threads

  1. Replies: 13
    Last Post: 12-12-2013, 07:22 PM
  2. Import Excel file based on a date and time in file name
    By nhylan in forum Import/Export Data
    Replies: 4
    Last Post: 04-16-2013, 03:26 PM
  3. Guidelines to design an Access Database
    By ravikiran in forum Access
    Replies: 3
    Last Post: 08-23-2012, 06:24 AM
  4. Replies: 31
    Last Post: 06-19-2012, 03:50 PM
  5. Replies: 10
    Last Post: 03-04-2012, 12:17 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Other Forums: Microsoft Office Forums