Connection strings on linked tables do not refresh properly!!

We use SQL Server 2k as the database and MS Access 2k as the client.We have two versions of the client, Training and production.Because each user's permissions are different we refresh the links tothe database with the following code:(rs contains a list of tables to be relinked)ConnectString = "ODBC;DRIVER={SQLSERVER};SERVER=myserver;DATABASE=Training;UID=" & Usr & ";PWD=" & Pwd& ";"Set db = CurrentDbrs.MoveFirstDo While Not rs.EOF   Debug.Print rs(0)   Set td = db.TableDefs(rs(0))   With td        .Connect = ODBC_STR        .RefreshLink   End With   db.TableDefs.Refresh   Debug.Print td.Connect   rs.MoveNextLoopWhat we have observed is that the link is not refreshing to point tothe training system - when I look at the sysobjects table, the linkson the tables still state "production" in stead of training but hasrefreshed the user's name.so instead of being:database=training;user=smithjit readsdatabase=production;user=smithjI have tried manually relinking the tables to the training system andchecked the sysobjects table and these links have been correct,  butoften, when the user logs in again, it changes the links back toproduction!!! despite the program connection string explicitly statingtraining.Does anyone know what is happening and how I can fix it? Is thereanyway I can edit the connection strings in msysobjects directly tofix them up?Or is there a better way?Thanks in advanceEdwinah63
0
Edwinah63
3/21/2007 1:59:20 AM
access 16762 articles. 3 followers. Follow

4 Replies
1268 Views

Similar Articles

[PageSpeed] 58

Just so I understand...> (rs contains a list of tables to be relinked)    Here you use the variable ConnectString> ConnectString = "ODBC;DRIVER={SQL> SERVER};SERVER=myserver;DATABASE=Training;UID=" & Usr & ";PWD=" & Pwd> & ";"     Here you use ODBC_STR>    With td>         .Connect = ODBC_STR>         .RefreshLink>    End With>    db.TableDefs.RefreshWhere does ODBC_STR originate from and what does it represent?
0
storrboy
3/21/2007 2:28:45 AM
Hi Storrboy,It should read: ODBC_STR = "ODBC;DRIVER={SQL SERVER};SERVER=myserver;DATABASE=Training;UID=" & Usr & ";PWD=" & Pwd & ";"Thanks for picking up the typo in the post.
0
Edwinah63
3/21/2007 5:19:39 AM
Can noone help me here?
0
Edwinah63
3/22/2007 8:48:12 AM
On Mar 22, 3:48 am, "Edwinah63" <edwi...@customercare.com.au> wrote:> Can noone help me here?Post the full code for doing the re-linking. You could have othererrors that cause it fail.
0
storrboy
3/22/2007 1:20:34 PM
Reply:

Similar Artilces:

Microsoft Document Connection gives error "Only connections to SharePoint or SkyDrive servers are supported."
Trying to connect to my SharePoint server using Microsoft Document Connection with Mac Office 2011. Getting this frustrating error: "Only connections to SharePoint or SkyDrive servers are supported." I have the full version of Mac Office 2011 (not student/teacher edition) and am running MOSS 2007 Service Pack 2 (12.0.0.6421) on my server. I have no problem connecting to SharePoint using anything else. Does anyone have any ideas? I have tried the basic authentication option, too but this has has no effect. Thanks in advance! Toby On Jan 25, 8:22=A0pm, Toby <tobybore...@gmail...

Outlook 2003: Cannot connect to Exchange Server 2000
We have installed Outlook 2003, and have configured it to connect to Exchange Server 2000. But each time we try to open any Exchange mailboxes in Outlook, we get the following error: "The set of folders could not be opened." The details button shows the follows: "This error usually appears if the OST or PST file you are using is: -Unavailable -Protected with file permissions -On a share on a server and the network is down -Corrupt To correct this problem, store the OST or PST file on the local computer. You may also want to run the scanost.exe and scanpst.exe tools t...

SBS Connectivity issues
Experiencing intermittent delays and dropped connections to Small Business Server. Config is: SBS2003 SP2 (all current patches) running on HP ML110 server; 4 PCs onsite - 3 used by onsite staff; 1 used by remote user to access server via RWW. Users run basic Office apps, Outlook, Quickbooks, internet access. Also have an Avaya VIOP phone system (4 phones) on the network. Everything has been in place for almost 4 years. Having more frequent connectivity issues. Onsite PCs show delays in Outlook connecting to Exchange ('Trying to connect ...). Remote user reports...

ODBC Connection Not Connecting
I am using the below code to 1) automatically connect to a Microsoft ODBC for Oracle connection called "FIN_CUR" and 2) run an query on a linked table in FIN_CUR The issue i am having is that the ODBC connect part of the script appears to be working, but when it goes to try to run the query I still get the popup prompting for user name and password to make the connection to the ODBC. I have verify that the user name and password are correct, but don't know what I am missing. Here is my code Public Sub OraConnect() Dim strErr As String On Error GoTo...

Simultaneous socket connections. Is there a limit?
My client wants me to write an application that maintains 30 or 40 simultaneous socket connections to different hardware devices. For each device the throughput requirements are very small since only some small packets are sent occasionally at random intervals. Is there a simultaneous limit? 30 or 40 is far more then I have ever done. I don't want any surprises. Is there a limit? I assume XP Professional would handle this. Correct? Would XP Home be any different? My laptop has XP home. To certain incoming ports, its 10, although there are several cracks out their to remove this...

Outlook Win98SE Trying to Connect to Server time out. IBM 390E & Rogers.com
I have loaded Win98SE and Office 97 on an IBM 390E laptop using IBM Etherjet 10/100 network card connected to a D- Link 714P+ 4-port wire&wireless cable router. Network file transfers work fine, IE 6 works fine. Outlook often hangs when it loads and trys to connect to the (Rogers.com) server to download email messages. I contacted Rogers tech support and all settings are correct. If I take the router out of the loop and connect directly to the cable modem - Outlooks works like a charm & fast downloading of messages. I have 3 other PCs connected on the LAN and all work fine...

VPN can't connect to workstations
I am running a 2k3 network and I am trying to connect my laptop w/ Vista to it using VPN. I can connect to the server and use server shares with no problem. My problem is that it cannot connect to the workstations . Would appreciate any input on that. "john" <johnbahran@hotmail.com> said this in news item news:b4419f87-386b-41de-876a-e3546096ecc2@c34g2000yqn.googlegroups.com... > I am running a 2k3 network and I am trying to connect my laptop w/ > Vista to it using VPN. I can connect to the server and use server > shares with no problem. My problem is ...

server connect
When I first start up Outlook 2003, it contacts the mail server and everything is hunky-doory. However, when attempting to next access the mail account by the send/receive access or in background, it indicates that it cannot locate the server and gives me error (0x80004210A). This error number is not consistent other than for the 0x800 portion. The location does not change, so how can it find it initially, and not later on? I'm confused. What type of mail server? POP3, IMAP, Exchange, HTTP, Other...? Does the same happen when you disable your firewall and/or virusscanner (integra...

IMAP: A connection to the server cannot be established
I have Outlook 2007 Installed on Two Separate PCs. One has Vista installed, and the other, Windows 7. McAfee Security Center is the Anti-Virus software unstalled on both PCs. I have setup 2 IMAP Accounts on each PC and can only get the ones on the Vista Box to work correctly. This is the error I keep getting on the Windows 7 Box: Task 'Synchronizing subscribed folders for [my-email-account].' reported error (0x800CCC0E) : 'Outlook cannot synchronize subscribed folders for [my-email-account]. Error: Cannot connect to the server. If you continue to receive this ...

Linked Servers
I would like to create two linked servers to the same data source. The first linked server has fairly open access to the database. The second linked server will have limited access to the database (readonly on one view). The two Linked Servers would be configured to access the database through different logins on the source server with different access to the same database. The first Linked Server works fine. I can't seem to configure a second linked server to the same datasource, even if I define the Server type as another data source. How can I create two linked s...

Intranet Connection
This is a multi-part message in MIME format. ------=_NextPart_000_0022_01C3CF10.F7EDF7A0 Content-Type: text/plain; charset="Windows-1252" Content-Transfer-Encoding: quoted-printable I am trying to connect 5 computers using Outlook XP intranet. What is = the best way to connect them....using MS mail, MS Exchange, etc. Thanks Douglas ------=_NextPart_000_0022_01C3CF10.F7EDF7A0 Content-Type: text/html; charset="Windows-1252" Content-Transfer-Encoding: quoted-printable <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN"> <HTML><HEAD>...

Hotmail connection
I'm new to Microsoft Outlook, and want to view and send email using Microsoft Outlook. I have used Hotmail for quite a while, and am looking for a method of "re-routing". (?) I played around with the configurations, but still could not connect to my hotmail accout through Outlook. Can any one help? Thanks. Which version of Outlook? Microsoft(R) Outlook(R) (9.0.0.2711) Internet Mail Only Copyright (c) 1995-1999 Microsoft Corp. All rights reserved. "miker67@gmail.com" wrote: > Which version of Outlook? > > zephyrus17 <zephyrus17@discussions.micros...

Indexes in tables.
Hi, Can I add index for tables in SQL Manager. For example for SOP30200 index for any field. Will it be a problem with program or not? Any other ways? Thanks, Vitali I believe any future upgrade will blow away your index. -- Charles Allen, MVP "Vitali V" wrote: > Hi, > > Can I add index for tables in SQL Manager. For example for SOP30200 index > for any field. Will it be a problem with program or not? > Any other ways? > > Thanks, > > Vitali > > > Suggest you leave the tables alone. You'll just get into a pickle.. "Char...

Table sorting and v look up possible &
Hello, Just need some advice with regards to the below. I have 2 tables. The first consists of 1 column of names and several other columns of other details. This table contains the records of people i need to update with details of the 2nd table.... The 2nd table contains 2 columns of the same names but split, with first name being in a separate column than the surname. Then further columns that have more info in. This table has 11000 peoples names in as this data is a simple data dump, opposed to the exact names of the people in table 1 i need. I will use a v look up but after i ha...

IE8 and Firefox won't connect to Yuku?
I've been having an issue tonight where my internet won't connect to the Yuku site first on IE8 then on Firefox, both sites got the same screen telling me it's an inactive site and I have connection issues. I ran the trouble shooter and it's telling me I don't have an issue? I'm on Windows 7 upgrade from XP, Windows Firewall is on, spyware is AVG and Spybot. I checked all the settings and nothing looked different as I was on the site like 2 days ago. Any ideas on what the problem is? Maybe you do have connection issues? 4thjet wrote: > I've been ...

Finding external links in a workbook
I have a workbook consisting of several largish worksheets emailed to me by a business contact. When I open it there is a warning that the workbook contains links to cells in other files (which of course I do not have because they are on my contact's computer not mine). Obviously I have to select the 'do not update' option. How do I locate the cells where these links are incorporated? The document is too large to examine cell by cell. BTW this is Excel 2000. John Check under 'Insert --> Name --> Define whether there are ranges linked to antoher workbook. If s...

Maintain network connectivity on shutdown?
Hello, we have added a script to run at Windows shutdown and in testing it seems to at least run, but the problem is part of the script process that needs to access a server on our network fails because it appears that network connectivity has been dropped at this point in the shutdown process. Is there any way to set it so that network connectivity is retained on shutdown? For example, if there is still at least IP connectivity (but the WINS service has been shutdown), then could we run something on a command line to invoke the network resource? Any help would be greatly appreci...

Email link to update Outlook --- Calendar #2
Anyone knows how to send an link within an email, inwhich the Recipient can click to have the their Outlook "Calendar" automatic updated with appointment information. I have seen this work, can't find inforamtion on how to create this link. Thanks Anthony wrote: || Anyone knows how to send an link within an email, inwhich || the Recipient can click to have the their || Outlook "Calendar" automatic updated with appointment || information. I have seen this work, can't find || inforamtion on how to create this link. Thanks In Calendar, right-click on the event...

Linking Charts to publisher file saved as web page
Good Day I hope someone can help me with this question - I am using publisher 2007 to create a newsletter ( Saved as web page ) on our local intarnet. I am now trying to add / link charts and excel tables to the newsletter. I am only able to paste as picture and have them dynamically update with daily sales for example. Can anyone help me with this . . . I am trying to find a way to insert excel charts and tables into my publisher 2007 webpage and have them automatically update when the excel files update - I do not want to copy and paste and re-publish everyday ...

Access Relationships (Oracle Tables)
In an attempt to bring our applications up to security standards, our tables have been recreated in Oracle. I have the ability to design the front end, however am having a difficult time with the relationships. If you have a one to many relationship enforcing referential integrity, how do you maintain that in access (assuming it was structured identically in Oracle). When I view the relationships and try and enforce referential integrity it doesn't allow me to..? How do I do this, should it come in automatically when I link the tables? Thanks in advance. On Tue, 22 Jan 200...

Programs to open links in Email
Hi I have this problem with Outlook. When I click on a link in an email I get the Following message Nvidia Windows 2000/XP display Drivers (install shield and setup) Antivirus software running, please select no, Disable the software, then restrat setup Otherwise click yes to continue. Whether I click yes or no does not matter as the link does not work. The big thing is are even if i nstall the software it does not help.I am using an ATI 9600 All in Wonder Video Card not an NVIDIA software or video card and have not used one for months William komar <anonymous@discussions.microsoft.com>...

link color
How do i change the default link color for composing messages in outlook 2003? thanks. ...

HowTo: Serialize to a String without extra characters
I have a class that I want to serialize to an XML string. I want the XML to serialize to utf-8 encoding. When I serialize to an XML file, the data looks great. When I try to serialize to a String (ala StringBuilder) I get utf-16 and instead of the parenthesis (") I get a slash and then a " (\") which makes sense when looking at a character in memory, but not in a string Here is my code XmlSerializer serializer = new XmlSerializer (myObject.GetType ()) StringBuilder builder = new StringBuilder () StringWriter stringWriter = new StringWriter (builder) XmlTextWriter xmlW...

Inconsistent table borders
Version: 2008 Operating System: Mac OS X 10.5 (Leopard) Processor: Intel I'm having problems with table borders in Word, particularly when printed to PDF. I can set all the borders in a table to be a particular weight, say 1/2 pt, but what I get in the generated PDF is mixed weights that look awful, sometimes giving the appearance of missing borders. Does anyone have any idea what is wrong? <br><br>Thanks, <br><br>Mark ...

No Internet connections in Network connections!!!
Hi im new to this forum and really need help. Yesterday I decided to set up my computer again (It had been in the garage because I wasn't using it for a while). Anyways, when I first started it up it worked fine and the internet connection worked as well. Later on it began to shut off unexpectedly if i tried to remove a program through task manager that wasn't working, so since it didn't have any important data, I decided to reformat my hardrive and reinstall microsoft xp. When I started up my cpu again, I noticed that there were no connections, even though I had not unp...