I need to make connections from my app to the server in the officeHello Joe,
Ask your network administrator to set up a VPN so that you can connect into
the office and communicate securely. Using a VPN is as simple to use as a
dial up connection. Usually easier because you don't have a modem to worry
about.
Aaron Weiker
http://aaronweiker.com/
http://sqlprogrammer.org/
> I need to make connections from my app to the server in the office
>|||I would like to be able to connect without using a VPN. One of the web
hosting companies with deal with just gave me a domain name to connect to. I
would like to do something like that.
"Aaron Weiker" <aaron@.sqlprogrammer.org> wrote in message
news:203279632424549284370779@.news.microsoft.com...
> Hello Joe,
> Ask your network administrator to set up a VPN so that you can connect
into
> the office and communicate securely. Using a VPN is as simple to use as a
> dial up connection. Usually easier because you don't have a modem to worry
> about.
> --
> Aaron Weiker
> http://aaronweiker.com/
> http://sqlprogrammer.org/
>
>|||Hello Joe,
You will need to get directions them from your web hosting company on how
to make the connection. I know the ones I use have step-by-step directions
which may vary depending on how they have it set up.
Aaron Weiker
http://aaronweiker.com/
http://sqlprogrammer.org/
> I would like to be able to connect without using a VPN. One of the web
> hosting companies with deal with just gave me a domain name to connect
> to. I would like to do something like that.
> "Aaron Weiker" <aaron@.sqlprogrammer.org> wrote in message
> news:203279632424549284370779@.news.microsoft.com...
>
> into
>|||I'm not going to be using their database. This is to connect to my own. I
was just using them as an example of what I want to do.
I haven't been able to find any information on how to do this.
Thanks,
Joe
"Aaron Weiker" <aaron@.sqlprogrammer.org> wrote in message
news:218108632425010745037690@.news.microsoft.com...
> Hello Joe,
> You will need to get directions them from your web hosting company on how
> to make the connection. I know the ones I use have step-by-step directions
> which may vary depending on how they have it set up.
> --
> Aaron Weiker
> http://aaronweiker.com/
> http://sqlprogrammer.org/
>
>|||Hello Joe,
Ok, if that's the case then all you need to do use your your database server
s
host name, IP to connect to the database. You'll also need to make sure that
you can connect via the correct ports from your hosted application.
I would not recomend this as you are allowing open connections to your datab
ase
across the internet. You should at least only allow connections from your
hosting company.
Aaron Weiker
http://aaronweiker.com/
http://sqlprogrammer.org/
> I'm not going to be using their database. This is to connect to my
> own. I was just using them as an example of what I want to do.
> I haven't been able to find any information on how to do this.
> Thanks,
> Joe
> "Aaron Weiker" <aaron@.sqlprogrammer.org> wrote in message
> news:218108632425010745037690@.news.microsoft.com...
>sql
Showing posts with label connections. Show all posts
Showing posts with label connections. Show all posts
Friday, March 30, 2012
Wednesday, March 28, 2012
How can I clear active connections without disabling the database?
To better explain the question let me build a scenario.
If someone is connected to the database there is an active connection, which does appear in Management Studio. If we try to do a restore of the database, SQL gives us a message saying that it cannot gain exclusive access to the database and the restore fails. To gain exclusive access to the database we need to clear the active connections.
Currently in Management Studio the only ways that I have found to clear the connections are to take the database offline or detach the database completely. What I would like to know is if there is another way to clear the active connections without have to take the database offline or detach it?
In SQL 2000 I could right-click the database, select all tasks, and then select detach database and click clear connections. Of course I would then have to make sure I clicked cancel otherwise I would mistakenly detach the database. This would clear the connections without taking the database offline.
If the only option in Management Studio to clear the connections is to disable the database I would like to request an option under tasks called clear connections. This way the server administrator could click on this to see the current active connections and clear them, either individually, or all of them without having to take the database offline or detach it.
Thanks in advance!
There are several ways you can do this without having to detach the database.
1. run sp_who2 to see all the SPIDs connected to your database. For each SPID, execute kill <spid #>
If someone is connected to the database there is an active connection, which does appear in Management Studio. If we try to do a restore of the database, SQL gives us a message saying that it cannot gain exclusive access to the database and the restore fails. To gain exclusive access to the database we need to clear the active connections.
Currently in Management Studio the only ways that I have found to clear the connections are to take the database offline or detach the database completely. What I would like to know is if there is another way to clear the active connections without have to take the database offline or detach it?
In SQL 2000 I could right-click the database, select all tasks, and then select detach database and click clear connections. Of course I would then have to make sure I clicked cancel otherwise I would mistakenly detach the database. This would clear the connections without taking the database offline.
If the only option in Management Studio to clear the connections is to disable the database I would like to request an option under tasks called clear connections. This way the server administrator could click on this to see the current active connections and clear them, either individually, or all of them without having to take the database offline or detach it.
Thanks in advance!
There are several ways you can do this without having to detach the database.
1. run sp_who2 to see all the SPIDs connected to your database. For each SPID, execute kill <spid #>
2. In Object Explorer, Click on Management -> Activity Monitor. RIght-click, select View Processes. From there, you can filter the proccesses any way you want, even by database. After that, you can right-click on each process and select Kill Process.
While it's not a one-shot command, you do have much more control over who gets disconnected.
|||I tried what you suggested and it works. I was curious still though if there are any plans to add a clear connections options that will allow us to clear all connections to a database with one click of a button, similar to SQL 2000.
sql
Subscribe to:
Posts (Atom)