[AccessD] Linked to SQL Server in a domain

Gustav Brock Gustav at cactus.dk
Fri May 22 03:31:04 CDT 2009


Hi John

A DSN can be created either as an Registry entry (which may be duplicated in the ODBC.INI file for the benefit of 16-bit apps, but let's forget that) or as a DSN file - in both cases either for the User or the System.

The DSN file is nothing more than a text file given the extension .dsn and can easily be moved. However, on another machine you still need to create a DSN for the database but, by referring to the file, no parameters need to be typed.

If no DSN file is available, a new DSN must be created from scratch.

Alternatively, a DSN can be created by code. This is probably not worth the efforts for a single user, but if you prefer this method I have extensive code for the purpose.

Finally, a DNS-less connection can be made as explained in the article. I find this method a bit over-hyped, one reason could be that many can't find out how to create a DSN. It is not the answer to everything but is well suited in some situations - as always, it depends. As you can see in the code in the article, it is just another method to pass the same information as contained in a DSN.

/gustav


>>> jwcolby at colbyconsulting.com 22-05-2009 00:47 >>>
Guys,

I am a tad out of my comfort zone here.  I am working on a database that links to a SQL Server using
ODBC.  The database was "upgraded" by another company which is in the process of being fired.  The
links work but I do not know where the DSN file resides.

I created a new database and a DSN for new tables that I created in that database and it works just 
fine for me, logged on to the server (which is where I work - remote desktop), but it does not work 
for another user that I have helping me test.  Those new links to the new table gives an ODBC error 
when she just tries to open the tables directly in the table tab of the db window.

I am assuming that is because the DSN file I used to do the link is not on her computer?  Is that
the way this works?  How do I discover where the DSN file is for the database that existed already
when I first got in?  I tried looking at the TDF cnn data and it isn't referenced in there.

I found this:

http://support.microsoft.com/kb/892490 

Which looks like the magic key.  Does anyone use this code or something similar?  Any comments, 
warnings?

Unfortunately at this point I am not able to log in to any other workstation there to test this code 
from another workstation.  I will have to get that figured out as well.

Any help appreciated.

-- 
John W. Colby
www.ColbyConsulting.com 






More information about the AccessD mailing list