473,323 Members | 1,537 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,323 software developers and data experts.

JDBC - connect timed out to SQL Server 2000

144 100+
hello,

i tried to connect to SQL Server 2000 on my localhost through JDBC. i used the Microsoft SQL Server JDBC Driver 2.0, i was trying to add a new Entity Class from Databases... in Netbean 6.7.1

i couldnt make it, as i got the following error

Expand|Select|Wrap|Line Numbers
  1. Unable to add connection. Cannot establish a connection to
  2. jdbc:sqlserver://localhost:1433;databaseName=Northwind using 
  3. com.microsoft.sqlserver.jdbc.SQLServerDriver (The TCP/IP connection 
  4. to the host localhost, port 1433 has failed. Error: "connect timed out. 
  5. Verify the connaction propoerties, check that an instance of SQL 
  6. Server is running on the host and accepting TCP/IP connections 
  7. at the port, and that no firewall is blocking TCP connections to the port.".).
  8.  
i've verified through Server Network Utility the the TCP/IP protocol is enabled and is listening on port 1433. but when i run the command "netstat -an" i don't see any service listening on port 1433.

i can connect to the database server through the query analyzer though,
what's possibly wrong? has there been any issue regarding to this?

Thank you.
Oct 12 '09 #1
1 4156
Dököll
2,364 Expert 2GB
Hey thesti!

Add the code in question, we recently switched to SQL 2005 from 2000. Not quick to say I know SQL Server like the back of my hands but there were times when I thought there must be a better way, I don't say that anymore.

Also, you may need credentials to connect your app to the server.

I would do some of the critical steps first. Write code that you know will work as far as a connection, so you can isolate the server being the issue.

Simple JDBC/ODBC connections with datasource:

Expand|Select|Wrap|Line Numbers
  1.  
  2. sun.jdbc.odbc.JdbcOdbcDriver
  3. jdbc:odbc:Northwind
  4.  
  5.  
Which means you'd need to try and connect to an Access database via Administrative Tools. If you can connect, then it is not your code or the server.

Then you would try sqlserver, with creds and see...

Alternatively, you can do likewsie with sqlserver with creds on Admin Tools to keep it simple for troubleshooting (Only do this locally, if app is promoted to full blown app server jdbc/odbc datasource via Admin Tools will have unfriendly results) :-)

Post what you have for a closer look, the whole thing... catch blocks and all:-) look into your creds, you will need those, except of course if the admins near leave it all open for all to see:-)

C-ya!
Nov 10 '09 #2

Sign in to post your reply or Sign up for a free account.

Similar topics

0
by: JShurmatz | last post by:
If anyone can shed some light on this problem I would greatly appreciate it. I am unsuccessfully trying to use a database connnection retrieved from a pool configured using Java System Web...
1
by: dfdfd | last post by:
I have a MSDE database that I am trying to connect to with JDBC. I don't have SQL Server installed. Is this possible? When I try to connect I get the error: java.sql.SQLException: Login...
0
by: Swami | last post by:
Hi, I have installed MQ SQL Server 2000 on my laptop and trying to use SPARTA 2000 JDBC Driver (inetmssql.jar) to connect to the local db. I wrote a sample Java app to test the connection and I...
6
by: Swami | last post by:
Hi, I have installed MQ SQL Server 2000 on my laptop and trying to use SPRINTA 2000 JDBC Driver (inetmssql.jar) to connect to the local db. I wrote a sample Java app to test the connection and I...
1
by: doniravi | last post by:
hello sir... i m using sql server 2000 database and usig jsp to access it when accessig i am getting followig error java.sql.SQLException: Unable to connect. Invalid URL. i installed...
2
by: bevis | last post by:
I'm new to sql server and mysql but this seems like it should be a pretty straight forward jdbc connection. But I have spent almost 2 days just trying to get a jdbc connection. Please help if you...
3
by: Anoop | last post by:
Is it true that there are no type 4 jdbc drivers to connect to a DB2 server v7.1? The DB2 server is hosted on ACF2 (OS/390). We would be connecting from windows and solaris boxes. If it is true,...
1
by: aj | last post by:
I'm a newbie w/ SQL Server 2005. We will be connecting to SQL Server 2005 via JDBC. We have made this work by using an SQL Server account, rather than an Active Directory (AD) account, even...
2
by: prasath03 | last post by:
Hi, I am using Microsoft SQL Server 2000 Driver for JDBC to connect to SQL Sever 2000. It is just a test application whether its connect or not. But I got the following errors: Error is:...
0
by: DolphinDB | last post by:
Tired of spending countless mintues downsampling your data? Look no further! In this article, you’ll learn how to efficiently downsample 6.48 billion high-frequency records to 61 million...
0
by: jfyes | last post by:
As a hardware engineer, after seeing that CEIWEI recently released a new tool for Modbus RTU Over TCP/UDP filtering and monitoring, I actively went to its official website to take a look. It turned...
0
by: ArrayDB | last post by:
The error message I've encountered is; ERROR:root:Error generating model response: exception: access violation writing 0x0000000000005140, which seems to be indicative of an access violation...
1
by: PapaRatzi | last post by:
Hello, I am teaching myself MS Access forms design and Visual Basic. I've created a table to capture a list of Top 30 singles and forms to capture new entries. The final step is a form (unbound)...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
1
by: Defcon1945 | last post by:
I'm trying to learn Python using Pycharm but import shutil doesn't work
1
by: Shćllîpôpď 09 | last post by:
If u are using a keypad phone, how do u turn on JavaScript, to access features like WhatsApp, Facebook, Instagram....
0
by: af34tf | last post by:
Hi Guys, I have a domain whose name is BytesLimited.com, and I want to sell it. Does anyone know about platforms that allow me to list my domain in auction for free. Thank you
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.