SQL Server General DBA

Transactions in SQL Server Part I – An Introduction

A basic requirements in most SQL Server based applications is implementing a database operation (DDL or DML) in a single unit of work. The DDL requirement is more from a DBA’s perspective rather than the application, since any application would perform only INSERTs, UPDATEs and DELETEs on the existing data, and a DBA would be […]

New Built-In TSQL Functions in SQL Server 2012

New Built-in Functions in SQL Server 2012 SQL Server 2012 (Code named SQL Server Denali) introduces 14 new built in functions in four different categories with one existing function (LOG) being modified to have an optional second base parameter: Category Function Name Conversion functions PARSE TRY_CONVERT TRY_PARSE Date and Time functions DATEFROMPARTS DATETIME2FROMPARTS DATETIMEFROMPARTS DATETIMEOFFSETFROMPARTS […]

Building Ranges using T-SQL

We often use excel for any running repetitive calculations since it is a very convenient user friendly interface which allows us to just enter a formula in a cell and  simply  drag and drop the  formulas to generate a complete output. For example, I had a Products listing, with ID and Quantity for each product. […]

Adding Custom Code to the Reporting Services 2008 R2

There are numerous circumstances when we wish to add a custom function to a SSRS report in order to cater for needs of the customer which exceeds the capability of the built-in functions in SSRS. In these scenarios we will have to write our own functions. In this article I will demonstrate how to add […]

New T-SQL Features in SQL Server 2012

SQL Server 2012 (or Denali) CTP is now available and can be downloaded at http://www.microsoft.com/downloads/en/details.aspx?FamilyID=6a04f16f-f6be-4f92-9c92-f7e5677d91f9&displaylang=en SQL Server 2012 has several major enhancements including a new look for SSMS. SSMS is now   similar to Visual Studio   with greatly improved Intellisense support. This article we will focus on the T-SQL Enhancements in SQL Server 2011. The main […]

SQL Server Log Shipping For Large Databases

Scenario:  A couple of days back I was setting up a DR plan for one of our most mission critical DB servers which was hosting around 10 databases having size of 10, 23, 5, 7.4, 1.8, 6.2, 7.9, 5.53, 8.7 and 125 GB respectively. I decided to implement Log Shipping as a part of the […]

Moving SQL Server System Databases

I was recently examining the configuration of one of our production database servers. This server was involved in Merge Replication. All the database files on this server were dumped on one small SAN drive. The replication cleanup job for some reason was unable to delete the historical records from the system tables present in the […]

Are You Using SSMS effectively ?

SQL Server Management Studio is an essential tool for DBAs and developers. But are you using it effectively?  In this article, I will try examine a few tips and techniques which could well boost your efficiency using SSMS. Object Filtering The below screen is probably familiar to most DBAs – it lists all tables under […]

Whether to use UNION or OR in SQL Server Queries

Recently I came across with an article on DB2 about using Union instead of OR. So I thought of carrying out a research on SQL Server on what scenarios UNION is optimal in and which scenarios OR would be best. I will analyze this with a few scenarios using samples taken  from the AdventureWorks database […]

Adding Column to a SQL Server Table

Adding a column to a table is  common task for  DBAs. You can add a column to a table which is a nullable column or which has default values. But are these two operations are similar internally and which method is optimal? Let us start this with an example. I created a database and a […]
Software Reviews | Book Reviews | FAQs | Tips | Articles | Performance Tuning | Audit | BI | Clustering | Developer | Reporting | DBA | ASP.NET Ado | Views tips | | Developer FAQs | Replication Tips | OS Tips | Misc Tips | Index Tuning Tips | Hints Tips | High Availability Tips | Hardware Tips | ETL Tips | Components Tips | Configuration Tips | App Dev Tips | OLAP Tips | Admin Tips | Software Reviews | Error | Clustering FAQs | Performance Tuning FAQs | DBA FAQs |