Results 1 to 6 of 6
  1. #1
    Tuckejam is offline Competent Performer
    Windows 10 Access 2010 64bit
    Join Date
    Jan 2020
    Posts
    168

    Invalid Table name when trying to link

    Now I really broke things.



    I had a table in sql server that needed changes that could not be made
    So I made a new table and with all the correct attributes then renamed it the same as the old table.

    then I tried to re-link the table in Access to the new table (with the same name as the old table)

    and it tells me that it is not a valid name (also it is adding "PK_" to the front of the name)

    I have done this before when creating a table in sql server and didnt have a problem what am i doing wrong

    Click image for larger version. 

Name:	Capture.PNG 
Views:	24 
Size:	32.0 KB 
ID:	45599

  2. #2
    ranman256's Avatar
    ranman256 is online now VIP
    Windows Vista Access 2010 32bit
    Join Date
    Apr 2014
    Location
    Kentucky
    Posts
    9,521
    Delete the table from access, then link it back in from scratch

  3. #3
    Tuckejam is offline Competent Performer
    Windows 10 Access 2010 64bit
    Join Date
    Jan 2020
    Posts
    168
    ranman256 - that was actually the first way I tried to go about it.

    what is also strange that I dont understand is that when I first created the table i named it ChapterDuesTrackNEW
    then when i was ready I renamed the table to the original ChapterDuesTrack

    however when it gives the error it is showing it as the name ChapterDuesTrackNEW (which shouldn't exist)

  4. #4
    davegri's Avatar
    davegri is offline Excess Access
    Windows 10 Access 2016
    Join Date
    May 2012
    Location
    Denver
    Posts
    3,388
    Take Ranman's step:
    Delete the table from access
    Then close and restart the Access DB then Ranman's second step:
    Then link it back in from scratch

  5. #5
    Minty is offline VIP
    Windows 10 Office 365
    Join Date
    Sep 2017
    Location
    UK - Wiltshire
    Posts
    3,001
    I would add a further step to the process as a belt and braces approach.

    1. Delete the table
    2. Compact and Repair the Database
    3. Then add it back in.

    Step 2 should remove any references to to any deleted items.
    DLookup Syntax and others http://access.mvps.org/access/general/gen0018.htm
    Please use the star below the post to say thanks if we have helped !
    ↓↓ It's down here ↓↓

  6. #6
    Tuckejam is offline Competent Performer
    Windows 10 Access 2010 64bit
    Join Date
    Jan 2020
    Posts
    168
    Well I still don't understand why it was telling me the table name was wrong, but once I matched the spelling in the new table column to the spelling in the old table columns things started working.
    the devil is always in the details!

    Thanks for you help

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

Similar Threads

  1. Replies: 3
    Last Post: 10-07-2019, 08:04 PM
  2. Replies: 4
    Last Post: 02-16-2017, 02:58 AM
  3. Make Table Query fails with invalid expression
    By BBrayton in forum Queries
    Replies: 11
    Last Post: 01-06-2015, 06:10 PM
  4. Replies: 5
    Last Post: 07-22-2014, 06:58 AM
  5. Replies: 7
    Last Post: 08-28-2011, 02:07 PM

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