I have developed an App using Delphi Xe3 and SQL Server 2008. Now the app is finished and compiled. I would like to run the app on another machine that is connected to the main Machine(running SQL Server) via Wifi. However when I run the app on another machine, I get the error " Server does not exist or access denied". I have enabled the SQL server for remote access enabled TCP/IP. Someone told me I would have to be running SQL server client on the other machine to access the server database. what am I missing to be able to run my app on machine B to share the database running on machine A.
I think sql server has remote connections off by default.
Run SQL Server management studio.
Right click on the server.
Properties
Connections
Under "Remote server connections", check on "Allow remote connections to this server"
For a default SQL instance don't add the name of the instance in the connection string Data Source. It somehow works when you test the connection from udl but does not work when you use the instance name in the Delphi app.
I've studied other topics, tried various solutions, but cannot gain access to my SQL Server remotely from my PC.
I have not problems with accessing the Server its running on, I'm able to Remote Desktop fine.
Here are the steps I have taken :-
Enabled Remote access to SQL Server
Created a SQL Authentication User Account (which Ii can log in with whilst on the server).
Enabled Shared Memory & TCP/IP Protocols for the SQL Server Instance.
Created a Firewall Rule for TCP Port 1433
Created a Firewall Rule for UDP Port 1434
Created a Firewall Rule for SQLBrowwer.exe
Created a Firewall Rule for SQLservr.exe
Ensured SQL Browser & SQL Server are running processes.
SQL Management Studio cant even detect the instance of the SQL Server in listed Database Engines.
I'm at a loss as to what the problem could be?
** UPDATE **
Ive tried turning off my Firewall, the SQL Server in now found in SSMS, but i still cant connect to it?
All your steps are right, I'd do the same. I'm sure everything is fine with your SQL Server.
I guess it's firewall, try to turn it off or run this from command prompt:
netsh firewall set portopening protocol = TCP port = 1433 name = SQLPort mode = ENABLE scope = SUBNET profile = CURRENT
Also, check if you have antivirus software or something similar and turn it off (on both sides).
I am trying to debug a stored Procedure from Microsoft SQL Server Management Studio 2008 which is connected to MS SQL Server 2008 Database Instance running on a different system.
System Information:
1. Remote system is running with Symantec End Point Security
I have done the following settings for running the remote debugger:
I have added the inbound Rules for TCP 139, TCP 445, UDP 137 and UDP 138 ports.
My local system's instance is running with sysadmin user role.
I have added the sqlservr.exe and svchost.exe at server windows firewall exception list.
I have added the svchost.exe and ssms.exe at client windows firewall exception list.
The SSMS and SQL server services are running in the same domain.
Following necessary services are running properly
TCP/IP NetBIOS Helper
Remote Registry
RPC Service
But after doing all these specified steps i am getting following error after clicking the debugger button in client SSMS.
Unable to start T-SQL Debugging. Could not attach to SQL Server process on 'remotesystem_name'. Click Help for more information.
If there is another alternative please let make me aware of that.
I solved this problem by creating a new login account (windows authentication account) on server for my machine.
firstly i recently installed this program as I’m working on a project to create a database to use in Microsoft visual studio.
This is the first time I’m using the program, so I’m having a few problems setting it up. I can't connect to a server because presumably i don't have one. I typed in my machine name to create a default/localhost server using windows authentication but i received an error.
Error:
TITLE: Connect to Server
A network-related or instance-specific error occurred while
establishing a connection to SQL Server. The server was not found or
was not accessible. Verify that the instance name is correct and that
SQL Server is configured to allow remote connections. (provider: Named
Pipes Provider, error: 40 - Could not open a connection to SQL Server)
(Microsoft SQL Server, Error: 2)
Could someone guide me on how i can setup up a local host to connect and thus be able to create my database. Also I’d like to know afterwards how i can create a server (ftp) to connect into and create my database there allowing me to view this on my laptop or a different machine.
Btw i have looked on Google for this, but I’m getting a bit confused, because I’m unsure what I’m searching for. If anyone can shed some light on my problem i would be greatly appreciated.
Thanks.
Does Your server name looks like : "localhost ( or IP of Your server
)"\"server name", E.G : localhost\SQLEXPRESS
Open application on Start -> -> Configuration Tools -> SQL Server Configuration Manager
Check, if MSSQL Server Service was started in :Sql Server Configuration Manager -> SQL Server Services. If not, right click on service and choose Start
Check on Configuration Manager on "SQL Server Network Configuration" does "TCP\IP" protocol is enabled and has "Listen All" enabled
Check, do You have firewall on port 1433
If that doesn't help, write a message
I faced same problem and I have solve this problem by doing following 2 step:
1st Task:
Open application on Start -> -> Configuration Tools -> SQL Server Configuration Manager
Check, if MSSQL Server Service was started in :Sql Server Configuration Manager -> SQL Server Services. If not, right click on service and choose Start
Check on Configuration Manager on "SQL Server Network Configuration" does "TCP\IP" protocol is enabled and has "Listen All" enabled
2nd Task:
Provide Server Name : [hostname]\SQLEXPRESS
Authentication : SQL Server Authentication or Windows authentication
Note:
If Server you have installed with Mixex mode then only it will work for SA (SQL Server Authentication) or else we need to used Windows authentication
Now you should be able to connect if you follow this 2 task.
-> Go To SQL Server Configuration Manager
-> Click to SQL Server Services
-> Right click to SQL Server(MSSQLSERVER) and click start, then see the magic.
One the main SQL Server Studio screen, enter for Server name:
\.\pipe\MSSQL$"your instancename"\sql\query
After a number of trials of restarting services in configuration manager, allowing port 1433 in firewall, restarting computer etc. nothing was working, at last I tried .\SQLEXPRESS ('.' represents localhost) rather than MYMACHINENAME\SQLEXPRESS and it worked straight away. Hope it will help someone.
Open Startup Menu and type 'SQL Server Configuration Manager'. After staring the utility select 'SQL Server Services'. Run 'SQL Server' service, that's all.
Right-click on 'SQL Server' service and select properties. Under service pane, set the 'Startup Mode' to automatic, so it will automatically start in future.
I had same issue but i tried to resolve it .
Please follow these steps to connect to your SQL server Management studios
Run->services.msc->search for SQL Server(MSSQLServer)->Right click on it and try to "start" running it.
By doing this you can surely solve connection issue of SQL server.
Alekya
I had this problem, So I enabled Named pipes protocol and it works for me.
Hi every one.
I find out the solution.
To establish connection follow these stips.
1.Click on Start >> Sql Server Management Studio.
Management studio windows will open .and will ask to connect to the sever name etc. Just cancel it the connect window.
Now you go to the left panel of your Object explorer which is Registered servers.
Click on Database engine.
3.It has normally a folder Local server group. Open it by clicking the plus sign.
which will show you your server name with cross sign ON.
4.Right click on it and then click on service control. and then click Start.
Now it will start your database engine.
5.Now double click on you engine and it will work as normal.
I installed an instance of SQL Server 2008 R2 Express on my 32 bit Windows 7 machine. I can see it and connect to it with SQL Server Management Studio locally but not on the network.
SQL Server Configuration Manager Settings
SQL Server Browser is running (Log on As "NT AUTHORUITY\LocalService")
Named Pipes for this instance are Enabled
TCP/IP Enabled Dynamic ports are set to nothing the TCP Ports are set to 1433
In the Server Properties from SSMS
Connections --> I have the "Allow remote connections to this server" box checked
The Firewall is turned off for testing
When I try to see this instance with a command prompt (sqlcmd -L) from another computer I get a list of network servers. Sometimes it shows up and sometimes it doesn't. If it shows up I still can't seem to connect and the error message number is 26. If feels like there is some switch somewhere that needs to be turned on.
I am leaving this up there for any other users who have mental blocks occasionally... I had not turned off all the firewalls. In windows7 you have three different firewalls and you have to turn off the right one