Win a copy of The Little Book of Impediments (e-book only) this week in the Agile and Other Processes forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Prolem in connection to Microsoft sql SErver

 
raminaa niilian
Ranch Hand
Posts: 551
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi
I have a very strange problem with SQLServer and Java
Before I upgrade to Windows XP media Center edition , everything works correctly.
Now i installed SQL server and other utils which i need . but none of them connect to sql server
I changed the authentication to MIXED mode and add user to sql Server
but when i try to connect to sql server from my java application it says :

SQL SERVER does not exist or access denied
or
Connection refused

can some one pleas help me to solve it ?what is wrong ?
i connect to sql server with Enterprise Manager , and also from a .net application with no peoblem (in both of them I used sql server authentication)
but none of my java applications connect to sql server any more.
 
Phillip Koebbe
Greenhorn
Posts: 27
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I don't have an actual answer for you, but a question that could potentially lead you toward the answer:

Is that new version of XP you installed up to SP2? I've heard all kinds of stories how the tightened "security" in SP2 cause a number of applications to break. You might dig into it.

Peace,
Phillip
 
raminaa niilian
Ranch Hand
Posts: 551
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi
exactly it has SP2
I forced to have win+sp2 because of other tools (.net 2005)
which i should use.
now even i disable all its security stuff and still my java application can not connect to it?

any solution ?

thank you
 
Paul Sturrock
Bartender
Posts: 10336
Eclipse IDE Hibernate Java
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Is TCP/IP an enabled protocol for your SQL Server instance? You could also check the network libraries are uptodate (I've seen simmilar issues with older versions of dlls being used with SQL Server.
 
Masoud Kalali
Author
Ranch Hand
Posts: 531
Java Mac OS X Netbeans IDE
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
By what you said it seems that TCP is enabled (you connect from .net)
and problem is Windows SP2 security stuff .
what you should do is very simple

1-get latest SP for sql server , it should be SP4
2-add MSSQL\Binn\sqlservr.exe to exceptions in firewall controlled in C panel.
add 1433 as A TCP port AND
4-Add 1434 as UDP port in exceptions section too

now restart the PC and you will have SQL server listening on the port.

any way : Allways check for open ports by using telnet . if telnet connect then some program is listening otherwise do not bother yourself with testing several programs over a port.

hope it helps
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic