How to test connection to SQL Server database

Asked

Viewed 5,466 times

2

I have an application that connects to SQL Server, but in a client terminal is returning a random error.

I wonder if there is a way to test the connection of this terminal with the Sqlserver server, isolated from my application. And if possible make a query.

When the bank is oracle I can do this with Tnsping and Sqlplus, but I don’t know how to test with Sqlserver.

It’s dripping on the bank server, the only test I could do.

S.O.: Windows 10

  • 1

    You can do a test with Telnet, Udl, or if you have the sql server client tools installed you can try with sqlcmd

  • There is no client of sqlserver installed in this terminal, telnet and sqlcmd does not work.. now I saw in the answer that has this udl.. I will test. Thank you. Thank you

  • 1

    You have to consider some things, by default SQL Express comes with remote connection disabled so if it is you have to enable, and in case of other version you have to check port 1433.

  • So the error is and one terminal only, the others are working.

1 answer

3


Create a new blank txt file on your computer that you would like to test:

inserir a descrição da imagem aqui

And then change your extension to . udl:

inserir a descrição da imagem aqui

Run this file and you can test the connection to the database: inserir a descrição da imagem aqui

  • It worked, thank you !

  • 2

    Just one observation regarding security. The files. udl when edited display information about the connection so be careful if you keep it saved.

Browser other questions tagged

You are not signed in. Login or sign up in order to post.