Free Microsoft SQL Server 2008 R2 E-Book

Microsoft Learning is offering a free E-Book on the latest release of SQL Server.  You only have to register to download it (quick registration I might add). Book Excerpt: “This book is for anyone who has an interest in SQL Server 2008 R2 and wants to understand its capabilities. In a book of this…


Reporting Services Error

Getting SQL Server Reporting Services up and running and then integrated with SharePoint can be a bit of a challenge.  There are just different pieces and too many areas where something can go wrong.  When testing your Report Server, you may get this dreaded error message: “The report server has encountered a configuration error. (rsServerConfigurationError)”. …


Report Builder 2.0 for SharePoint 64 bit Integration

When you integrate SSRS with SharePoint, by default the Report Builder is 1.0.  You can install the Report Builder 2.0 and configure SharePoint to use it instead.  But you are going to run into issues if your SharePoint environment is 64-bit.  Reporting Services Add-in for SharePoint products and technologies is not installed. It must be…


Kill database connections to SharePoint

There will be occasions where you need to work with the databases for SharePoint in SQL Server Management Studio.  Backups, restores, etc… If you run into problems with there being existing connections to the databases preventing you from performing maintenance items, here’s a way to kill those database connections. Management > Activity Monitor > View…


What service pack is on my SQL Server?

Quick way to determine which SP is on your SQL Server:  "If you are a DBA in a big SQL Server database shop, keeping track of what service packs are on each SQL Server can become daunting. Here are a couple of scripts that help you determine what service pack you are running on a…


SharePoint Crawl and SQL Server Errors – Event ID: 17310

After setting up a crawl rule to crawl something other than SharePoint sites (such as a file share), you may encounter some errors for SQL Server.  If you start to see these repeatedly – check that you have the latest service pack for Microsoft SQL Server 2005 installed.  That will resolve your issue.  Event Type:…


Change default location for SharePoint Database files: .mdf .ldf

When installing SharePoint, you may have decided you want to keep your data files for the database on a separate directory / drive.  However, you need to keep in mind that the SharePoint installer is going to create the databases for you automatically.  To change where the config and content databases are created, you need…


SQL Script to attach a database

note: this script detaches it first   EXEC sp_detach_db @dbname = ‘dbnametoattach’ EXEC sp_attach_single_file_db @dbname = ‘dbnametoattach’, @physname = ‘c:\yourdirectory\dbnametoattach.mdf’   – Dan Lewis


Turn Identity Insert Off and On

This is a really great thing to know if you are migrating data from one database to another and absolutely must retain the Id field of your records.  You can turn Indentity Insert Off / On so that you can specify the Id during insertion. Don’t get confused like I did though – it’s reverse…


Add a Column To An Existing Table

If you need to add a column to an existing table with a default value:   ALTER TABLE YourTableName ADD YourColumnName varchar(50) DEFAULT ‘your default value’ WITH VALUES