Solved

MS Access Linked Tables

Posted on 2014-03-12
4
851 Views
Last Modified: 2014-03-12
See attached.

2 questions

(1) Note the table Customer. I'm guessing that the arrow and green ball to the left of table name mean linked to something else. How can I determine what "something else" is?

(2) If I "open" the table, it takes quite a while and it looks like what is there is NOT all the fields in the target table, Does this "link" have to be updated if other daya is added to the "source" table? If so, how do I do that?

Thanks
linked-access-tables.jpg
0
Comment
Question by:Richard Korts
4 Comments
 
LVL 34

Accepted Solution

by:
PatHartman earned 300 total points
ID: 39924355
The globe indicates an ODBC connection.  If you leave your mouse pointer over the table name, you will see the connection string which tells you what server it is connected to.  You could query the MSysObjects table.  The query below selects all tables whether they are linked or not.  Change the selection criteria to suit yourself.

SELECT MSysObjects.Connect, MSysObjects.Database, MSysObjects.ForeignName, MSysObjects.Name, MSysObjects.Type
FROM MSysObjects
WHERE (((MSysObjects.Name) Not Like "MSys*") AND ((MSysObjects.Type)=1 Or (MSysObjects.Type)=4 Or (MSysObjects.Type)=6))
ORDER BY MSysObjects.Connect, MSysObjects.Database, MSysObjects.ForeignName, MSysObjects.Name;

Open in new window


When you make structural changes to a linked ODBC table, Access doesn't always "see" the changes.  Sometimes you will receive an error message but not always so best practice is to relink any time you make a schema change to a linked table.
0
 
LVL 20

Assisted Solution

by:GrahamMandeno
GrahamMandeno earned 200 total points
ID: 39924367
The icon indicates it is a linked table from an ODBC source.  Hovering the mouse over it may give you some information.  If you need more, go to the Immediate Window (Ctrl-G) and type:
?CurrentDb.TableDefs("Customer").Connect
and then
?CurrentDb.TableDefs("Customer").SourceTableName

These commands will display the connect string (which gives the type and location of the external database) and the name of the source table in that database.

I'm not sure what you mean by "NOT all the fields in the target table".  You could try refreshing the link:

CurrentDb.TableDefs("Customer").RefreshLink

Best wishes,
Graham Mandeno [Access MVP 1996-2014]
0
 

Author Comment

by:Richard Korts
ID: 39924387
How do you relink or refresh the link?

Thanks
0
 
LVL 84
ID: 39924554
How do you relink or refresh the link?
You use the Linked TAble Manager, or you write code to refresh/recreate the links.

Looks like you're using 2003, so you'd find that on Tools - Database Utilities.
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

QuickBooks® has a great invoice interface that we were happy with for a while but that changed in 2001 through no fault of Intuit®. Our industry's unit names are dictated by RUS: the Rural Utilities Services division of USDA. Contracts contain un…
Describes a method of obtaining an object variable to an already running instance of Microsoft Access so that it can be controlled via automation.
Get people started with the utilization of class modules. Class modules can be a powerful tool in Microsoft Access. They allow you to create self-contained objects that encapsulate functionality. They can easily hide the complexity of a process from…
Familiarize people with the process of retrieving data from SQL Server using an Access pass-thru query. Microsoft Access is a very powerful client/server development tool. One of the ways that you can retrieve data from a SQL Server is by using a pa…

895 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

14 Experts available now in Live!

Get 1:1 Help Now