By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
424,679 Members | 2,069 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 424,679 IT Pros & Developers. It's quick & easy.

DSN and linked table ?

P: n/a
Hi!

What happens with linked tables if they were linked using File DSN, when I
copy the Access file on some other PC without File DSN ?
What is the difference between DSN on linked tables and pass-through queries
? Why I can change DSN for pass-through query and can't change it for linked
table, in Properties dialog box ?

Zlatko
Nov 13 '05 #1
Share this Question
Share on Google+
3 Replies


P: n/a
On Wed, 18 May 2005 17:06:09 +0200, "Zlatko Matić" <zl***********@sb.t-com.hr>
wrote:
Hi!

What happens with linked tables if they were linked using File DSN, when I
copy the Access file on some other PC without File DSN ?
DSNs are set up for each machine. If you link a table using a DSN, then the
link will only work so long as a DSN with the same name exists on the machine
you're trying to use the database from.
What is the difference between DSN on linked tables and pass-through queries
A pass-through query passes literal SQL to the server exactly as you write it.
With linked tables, Access/JET decides how to query the server. If you make
an Access query of linked tables, JET will do its best to generate server-side
SQL to run it - it mostly does a very good job.
? Why I can change DSN for pass-through query and can't change it for linked
table, in Properties dialog box ?


You can change the connect string for a linked table using the Linked Table
Manager.

Nov 13 '05 #2

P: n/a
How can I change connection string for linked tables programmatically?
ro example, let's say that I have a login form and a procedure that creates
connection string using login information, so that I can use DSN-less
connection ?
How can I pass that connection string to linked tables every time when user
logs ?

"Steve Jorgensen" <no****@nospam.nospam> je napisao u poruci interesnoj
grupi:lv********************************@4ax.com.. .
On Wed, 18 May 2005 17:06:09 +0200, "Zlatko Matić"
<zl***********@sb.t-com.hr>
wrote:
Hi!

What happens with linked tables if they were linked using File DSN, when I
copy the Access file on some other PC without File DSN ?


DSNs are set up for each machine. If you link a table using a DSN, then
the
link will only work so long as a DSN with the same name exists on the
machine
you're trying to use the database from.
What is the difference between DSN on linked tables and pass-through
queries


A pass-through query passes literal SQL to the server exactly as you write
it.
With linked tables, Access/JET decides how to query the server. If you
make
an Access query of linked tables, JET will do its best to generate
server-side
SQL to run it - it mostly does a very good job.
? Why I can change DSN for pass-through query and can't change it for
linked
table, in Properties dialog box ?


You can change the connect string for a linked table using the Linked
Table
Manager.

Nov 13 '05 #3

P: n/a
On Wed, 18 May 2005 22:33:02 +0200, "Zlatko Matic" <zl***********@sb.t-com.hr>
wrote:
How can I change connection string for linked tables programmatically?
ro example, let's say that I have a login form and a procedure that creates
connection string using login information, so that I can use DSN-less
connection ?
How can I pass that connection string to linked tables every time when user
logs ?


I'm posting this from memory now, but it's something close to...

1. Get a reference to the tabledef from the database's Tabledefs collection
2. Set the Connect property to the connect string you want
3. Call the RefreshLink method of the tabledef object.
Nov 13 '05 #4

This discussion thread is closed

Replies have been disabled for this discussion.