title: SQL Script to take a Microsoft Sql database online or offline?
body: <p>If I wish to take an MS Sql 2008 offline or online, I need to use the GUI -> DB-Tasks-Take Online or Take Offline.</p>
  
  <p>Can this be done with some sql script?</p>