Solved

how to solve time out connection to SQL server from access VBA

Posted on 2014-01-17
4
1,259 Views
Last Modified: 2014-01-30
I am getting this error while trying to connect and link in tables from Access vba to SQL Server.
Connection Failed:
SQLState: '01000'
SQL Server Error: 53
[Microsoft][ODBC SQL Server Driver][DBNETLIB][ConnectionOpen(Connect()).
Connection Failed:
SQLState: '08001'
SQL Server Error: 17
[Microsoft][ODBC SQL Server Driver][DBNETLIB]SQL Server does not
exist or access is denied.
I found solution on the link below, but i am not sure how to implement it.

stackoverflow.com/questions/15120143/handling-a-sql-server-login-error-msg-with-vba/15277960#15277960


Any help would be apreciated.
0
Comment
Question by:maximyshka
4 Comments
 
LVL 26

Accepted Solution

by:
Zberteoc earned 250 total points
ID: 39789459
That is not a timeout error but a permission one as it clearly states:

"[Microsoft][ODBC SQL Server Driver][DBNETLIB]SQL Server does not
exist or access is denied."

You either miss-typed something or you need to open remote access to that SQL server and/or the ports.
0
 
LVL 12

Assisted Solution

by:thausla
thausla earned 250 total points
ID: 39792052
Agree with Zberteoc, this is not a time out but you either
- have used the wrong name for the SQL Server in your connection string (check FQDN and if you can ping this name)
- or have used a wrong username and password in your connection. or your Windows account is not able to connect if you use SSPI for security
- or the SQL server doesn't allow external connections for TCP or Named Pipes (check with your DBA)
0
 
LVL 24

Expert Comment

by:Bitsqueezer
ID: 39799201
Hi,

another possible error is if you do not use the FQDN (full qualified domain name) of the server. If you are working in a different domain and you only use the short name of the server itself then it can happen that the server name cannot be resolved (depending on the quality of your local DNS).
So instead of "YourServer" use something like "YourServer.domain.domain.com". If you have a named instance, add that at the end like: "YourServer.domain.domain.com\MyInstance"

Cheers,

Christian
0
 

Author Comment

by:maximyshka
ID: 39821569
I actualy misspelled rthe server name. We have very long server names so I wrote o insteadof 0 :-(
0

Featured Post

Backup Your Microsoft Windows Server®

Backup all your Microsoft Windows Server – on-premises, in remote locations, in private and hybrid clouds. Your entire Windows Server will be backed up in one easy step with patented, block-level disk imaging. We achieve RTOs (recovery time objectives) as low as 15 seconds.

Join & Write a Comment

Background What I'm presenting in this article is the result of 2 conditions in my work area: We have a SQL Server production environment but no development or test environment; andWe have an MS Access front end using tables in SQL Server but we a…
In this article I will describe the Copy Database Wizard 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.
Familiarize people with the process of utilizing SQL Server stored procedures from within Microsoft Access. Microsoft Access is a very powerful client/server development tool. One of the SQL Server objects that you can interact with from within Micr…
What’s inside an Access Desktop Database. Will look at the basic interface, Navigation Pane (Database Container), Tables, Queries, Forms, Report, Macro’s, and VBA code.

762 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

13 Experts available now in Live!

Get 1:1 Help Now