Results 1 to 4 of 4
  1. #1
    VAer's Avatar
    VAer is offline Competent Performer
    Windows 10 Access 2013 32bit
    Join Date
    Sep 2016
    Location
    USA
    Posts
    163

    Where are these Access table names come from?

    I have only three tables (two Access tables and one linked Sybase table), but when I loop through table name, it loops through so many crazy table names.



    Intention of code: I use acLink to like a Sybase table(this is one time only code), but need the code to Refresh the table when opening the Access file again.

    Thanks.

    Click image for larger version. 

Name:	Tablename.jpg 
Views:	13 
Size:	23.1 KB 
ID:	35508

    Click image for larger version. 

Name:	Three Tables.JPG 
Views:	13 
Size:	14.4 KB 
ID:	35509

    Code:
    Dim AccessDB As dao.Database
    Dim Tbl As TableDef
    
    ......
    ......
    Set AccessDB = CurrentDb
    ......
    ......
    
    For Each Tbl In AccessDB.TableDefs
        If Tbl.Name = "Test_RecordT" Then
            Tbl.Connect = "ODBC;DSN=ABC;UID=" & Username & ";PWD=" & Password & ";LANGUAGE=us_english;DATABASE=XYZ"
            Tbl.RefreshLink 'Relink the table
        End If
    Next Tbl

  2. #2
    isladogs's Avatar
    isladogs is offline Access MVP / VIP
    Windows 10 Access 2010 32bit
    Join Date
    Jan 2014
    Location
    Somerset, UK
    Posts
    6,204
    Possibly system tables needed to make your application work.
    Most of these start with MSys.
    Leave them alone.

    However items starting with ~TMPCLP are deleted objects that weren't completely removed as your database crashed at some point rather than being closed properly.
    For a detailed explanation on removing these items, see this link https://www.access-programmers.co.uk...d.php?t=293579
    Colin Riddington, Access MVP, Website, email
    The more I learn, the more I know I don't know. When I know I don't know, I keep quiet!

  3. #3
    VAer's Avatar
    VAer is offline Competent Performer
    Windows 10 Access 2013 32bit
    Join Date
    Sep 2016
    Location
    USA
    Posts
    163
    Quote Originally Posted by ridders52 View Post
    Possibly system tables needed to make your application work.
    Most of these start with MSys.
    Leave them alone.

    However items starting with ~TMPCLP are deleted objects that weren't completely removed as your database crashed at some point rather than being closed properly.
    For a detailed explanation on removing these items, see this link https://www.access-programmers.co.uk...d.php?t=293579
    Ok, I will leave all of them alone, if they don't bother my code.

  4. #4
    isladogs's Avatar
    isladogs is offline Access MVP / VIP
    Windows 10 Access 2010 32bit
    Join Date
    Jan 2014
    Location
    Somerset, UK
    Posts
    6,204
    I meant to stress that you must leave system tables alone.

    However, personally I would suggest removing all ~TMPCLP objects. It's easy to do.
    Colin Riddington, Access MVP, Website, email
    The more I learn, the more I know I don't know. When I know I don't know, I keep quiet!

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

Similar Threads

  1. Replies: 7
    Last Post: 03-21-2018, 04:58 AM
  2. Replies: 2
    Last Post: 01-08-2018, 06:23 PM
  3. How Access update two table without field names?
    By llgtjb001 in forum Queries
    Replies: 16
    Last Post: 09-10-2015, 03:15 PM
  4. Replies: 7
    Last Post: 08-20-2014, 03:00 AM
  5. Replies: 6
    Last Post: 12-28-2012, 01:26 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