Solved

Access front-end SQL back-end : quickly switch between prod & dev box

Posted on 2014-11-14
3
153 Views
Last Modified: 2014-11-17
Hi All,

I have two boxes - prod & dev. I have an Access 2007 front end, with an SQL back end.

I'm looking for the quickest way to switch the entire DB between pointing at the different boxes.

Unfortunately, I connect to the server in pretty much every way possible, including VBA (ADO & DAO), pass through queries, linked tables.

Now this is fairly easy to do in VBA for the coded connections, but I wonder whether there's quick way of doing the same for all my pass through queries and tables.

Does anyone have any pre-scripted routines? Or perhaps there's a way to make the connections rely on a central file wherein I can change the connection string?

Any pointers would be appreciated.

Thanks
0
Comment
Question by:James Elliott
3 Comments
 
LVL 32

Expert Comment

by:Stefan Hoffmann
Comment Utility
First of all: It requires a restart of Access to do it safely. Cause connection pooling may interfere here.

Then you do the same as the table link manager, just in your code. You set the Connect property for each object which is affected.
0
 
LVL 34

Accepted Solution

by:
PatHartman earned 500 total points
Comment Utility
I've attached a sample extracted from one of my applications.  We had two databases and three stages - test, QA, and Prod.  It relinks the pass through queries and rebuilds the pseudo indexes that make linked views updateable.
RelinkODBC-POMS140228.zip
0
 
LVL 12

Author Closing Comment

by:James Elliott
Comment Utility
Just what I was hoping for. Thanks!
0

Featured Post

Maximize Your Threat Intelligence Reporting

Reporting is one of the most important and least talked about aspects of a world-class threat intelligence program. Here’s how to do it right.

Join & Write a Comment

In this article I will describe the Backup & Restore method as one possible migration process and I will add the extra tasks needed for an upgrade when and where is applied so it will cover all.
This article explains how to reset the password of the sa account on a Microsoft SQL Server.  The steps in this article work in SQL 2005, 2008, 2008 R2, 2012, 2014 and 2016.
In Microsoft Access, learn how to “cascade” or have the displayed data of one combo control depend upon what’s entered in another. Base the dependent combo on a query for its row source: Add a reference to the first combo on the form as criteria i…
In Microsoft Access, when working with VBA, learn some techniques for writing readable and easily maintained code.

763 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

6 Experts available now in Live!

Get 1:1 Help Now