title: How to drop a database when it's currently in use?
body: <p>NB. I don't want to mark the check box in the wizard for deletion. This question's <strong>strictly</strong> about scripting the behavior.</p>
  
  <p>When I run the following script to get a fresh start, I get the error that the database <em>Duck</em> can't be deleted because it's currently in use.</p>
  
  <pre><code>use Master
  drop database Duck
  drop login WorkerLogin
  drop login AdminLogin
  go
  </code></pre>
  
  <p>Be that as it may (even though I'm the only user currently in the system and I run no other queries but that's another story), I need to close all the existing connections. One way is to wait it out or restart the manager. However I'd like to script in that behavior so I can tell the stubborn server to <em>drop</em> the duck down. (Yes, "typo" intended.)</p>
  
  <p>What do I need to add to the dropping statement?</p>