Got more questions? Find advice on: ASP | XML | Regular Expressions | Windows
in Search
Welcome to SqlAdvice Sign in | Join | Help

Browse by Tags

All Tags » SQL Server » Database Maintenance
  • Change Login's Default Database in SQL Server

    If you have ever dropped a database and found yourself not able to login because your default database no longer exists you know it can be quite annoying.  You can still connect through query analyzer by connecting to a different database, but you won't be able to do anything through the object explorer as it always defaults to your default ...
    Posted to Gregg Stark on SQL Server (Weblog) by gstark on October 16, 2007
  • Retrieve Index Details and Columns in Sql Server 2005

    I frequently need to look at what indexes are on a table and I am really not a fan of using object explorer in SSMS as I like to stay in the query window.  Typically if I want information about a table I simply highlight the table name in the query window and hit Alt-F1.  If you aren't familiar with keyboard shortcuts in SSMS see my post ...
    Posted to Gregg Stark on SQL Server (Weblog) by gstark on October 10, 2007
  • Enable XP_CMDSHELL in SQL Server 2005

    I needed to use xp_cmdshell recently and discovered that it isn't on by default on SQL Server 2005.  I had to dig a bit to find out how to enable it.  The code is very simple.  Figured I would blog it here so I can easily find it next time.   EXECUTE sp_configure 'show advanced options', 1 RECONFIGURE WITH ...
    Posted to Gregg Stark on SQL Server (Weblog) by gstark on September 27, 2007
  • Move TempDB Sql Server 2005

    I recently needed to move the TempDB on my Sql Server so I looked in Books Online and my initial thought based on what it said was that there is no way that will work.  Basically it says to find where the files are, and then move them to the new location followed by an alter statement to point the database at the new location.  Well of ...
    Posted to Gregg Stark on SQL Server (Weblog) by gstark on August 20, 2007