logout of users from the application

  • I have a web application running on sql server 2000. In order to do restore i need to  logout of the users from the application. How to accomplish this/

    Thanks in advance

     

  • In your target database if you are unconcerned with the connections and need to rapidly (can be dangerous and advantagious) you can

    1.Kill All connections in the Target database

    2. Set it off-line 

    3. Restore the db.

    4. Resolve users.

    Here is an example script url http://www.sqlservercentral.com/scripts/contributions/1011.asp

    Becarefull !

    Jim Babington

    Jbabington@hotmail.com

     

    Jbabington
    Jbabington@hotmail.com

  • I just go to the database, right click, select detach database and click on the clear button in the detach database dialog box.

     

  • Under SQL2000 the quick way to accomplish Jim's steps 1 and 2 is:

    use master
    alter database MyDatabase set offline with rollback immediate

    Then do your restore


    Cheers,
    - Mark

  • Good Point Mark !

     

    Jim Babington

    Jbabington
    Jbabington@hotmail.com

Viewing 5 posts - 1 through 4 (of 4 total)

You must be logged in to reply to this topic. Login to reply