|
Home > Archive > microsoft.public.sqlserver.server > October 2002 > Disconncted Connections
You are viewing an archived Text-only version of the thread.
To view this thread in it's original format and/or if you want to reply to
this thread please [click here]
| Author |
Disconncted Connections
|
|
|
| Hello all,
We have SQL Server 2000 running on Windows 2000. When we
logoff it still shows the login exists esp. it prevents us
from doing database restores etc. But once the application
(eg. DBartisan or Enterprise Manager) which was used to
logon to the SQL server is complety closed the SQL Server
allows us to restore the database.
Is there a way to overcome this situation without closing
the app?
Thanks,
Ashu
| |
| Ron Talmage 2002-10-31, 12:24 pm |
| Ashu,
I don't know about DB Artisan, but with Enterprise Manager, you can right
click over the server name and completely disconnect without closing, or you
can select a different database to change the context so that you can
restore into the original database.
Ron
--
Ron Talmage
SQL Server MVP
"Ashu" <ashutosh.butala@prometric.com> wrote in message
news:daf301c280f3$8281d430$39e
f2ecf@TKMSFTNGXA08...
> Hello all,
>
> We have SQL Server 2000 running on Windows 2000. When we
> logoff it still shows the login exists esp. it prevents us
> from doing database restores etc. But once the application
> (eg. DBartisan or Enterprise Manager) which was used to
> logon to the SQL server is complety closed the SQL Server
> allows us to restore the database.
> Is there a way to overcome this situation without closing
> the app?
>
> Thanks,
>
> Ashu
>
>
| |
| Bill Hollinshead [MS] 2002-10-31, 2:23 pm |
| Hi Ashu,
Consider the ALTER DATABASE command's RESTRICTED_USER and ROLLBACK
IMMEDIATE options (see
http://msdn.microsoft.com/library/e..._aa-az_4e5h.asp).
Alternatively, in Enterprise Manager, use the Current Activity window
(http://msdn.microsoft.com/library/e...erfmon_6ofn.asp) to
kill/terminate any process using that database
(http://msdn.microsoft.com/library/e...sr1pem_5589.asp) or
in T-SQL EXECute sp_who (look at the dbname and spid columns to determine
who is in what database) and then use the T-SQL KILL <spid_number> command.
However, a kill will not stop another (new) connection from being made by
any client (and will cause a ROLLBACK of any uncommitted transaction that
may have been submitted by that spid). SQL Server will not let you commit
suicide <g>.
Thanks,
Bill Hollinshead
Microsoft, SQL Server
This posting is provided "AS IS" with no warranties, and confers no
rights. Subscribe to MSDN & use http://msdn.microsoft.com/newsgroups.
|
|
|
|
|