Go Premium for a chance to win a PS4. Enter to Win

x
?
Solved

Script to change ODBC connections

Posted on 2015-02-18
1
Medium Priority
?
117 Views
Last Modified: 2015-02-19
I need to change multiple ODBC connection - DSNs, can this be done via a script?

Currently we would have an ODBC connection with the below information

Name: comrcn02ddsspxx
Server: comrcn02ddsspxx
Database: unifi
Username: report
Password: xxxxx

It would need to change to this with the server, username and password changing

Name: comrcn02ddsspxx
Server: lsdad2
Database: unifi
Username: mtg_br_readonly
Password: xxxxxx
0
Comment
Question by:gilweber3
1 Comment
 
LVL 71

Accepted Solution

by:
Qlemo earned 1500 total points
ID: 40617493
A common way is to export the settings from registry and back. DSNs are stored in HKLM\Software\ODBC\Odbc.ini respective HKCU.
0

Featured Post

[Webinar] Cloud and Mobile-First Strategy

Maybe you’ve fully adopted the cloud since the beginning. Or maybe you started with on-prem resources but are pursuing a “cloud and mobile first” strategy. Getting to that end state has its challenges. Discover how to build out a 100% cloud and mobile IT strategy in this webinar.

Question has a verified solution.

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

In this tutorial I will show you how to provide a dynamic RTF document on your website generated with data from your database. For this tutorial you will need Microsoft Word or WordPad, WhizBase and Microsoft Access. In this tutorial I will show …
Batch, VBS, and scripts in general are incredibly useful for repetitive tasks.  Some tasks can take a while to complete and it can be annoying to check back only to discover that your script finished 5 minutes ago.  Some scripts may complete nearly …
This tutorial will teach you the core code needed to finalize the addition of a watermark to your image. The viewer will use a small PHP class to learn and create a watermark.
The viewer will learn how to create a basic form using some HTML5 and PHP for later processing. Set up your basic HTML file. Open your form tag and set the method and action attributes.: (CODE) Set up your first few inputs one for the name and …
Suggested Courses

963 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