Archive: Adding an ODBC DSN


I am trying to create an ODBC DSN for Access to use. I would like for it to go into the System DSN folder if at all possible.

Has anyone attempted this? Is this outside the scope of this tool? If not please let me know.

Sixty4Bit


I don't like to see posts going unanaswered so I thought I'd better reply to this one. Sorry I can't answer you're question, I'm another person who'd like to know this though. Is it just a case of adding a registry key pointing to the database file??? or maybe it's a bit more complicated than that


Answer Found
This is pretty easy to fix. All DSN's are just entries into the Registry in HKLM\Software\ODBC\ODBC.INI You can find the driver in HKLM\Software\ODBC\ODBCINST.INI.

So, I am checking to ensure the driver has been installed for Oracle, if not it skips that portion of the install with a msg box informing the user that Oracle needs to be installed. If the Oracle driver is installed then there are about 17 Registry entries that have to be made to create the DSN.

Getting the server name was a problem and I didn't want to hard code it, so I created a little perl executable that takes care of the server entries for me in the appropriate configuration files.

I hope this helps others.

Sixty4Bit