3 Best resources for Reporting Services and RDL

SQL Server Reporting Services or SSRS is getting more and more popular. Although in my opinion it needs much more features to challenge the Reporting King Crystal Reports but if you see the growth rate of Reporting Services implementations and improvements in feature set it shows you a promising future.
The best thing which I like [...]

Orphan Users of SQL Server are no longer Orphan

Sometimes after restoring database, you found that your sql server users are no longer working. This happens because of the database restore from one database server to another database server. An Orphan User is a SQL Server user which is not linked to a SQL Server Login. Following is a handy TSQL script which [...]

SQL Server 2008 Release Date

Microsoft has announced the release date for SQL Server 2008. It will be launched along with Windows Server 2008 and Visual Studio 2008 on 27 Feb 2008.
For further information please visit here

Generate script of each object on a separate file in SQL Server 2005 Management Studio

In SQL Server 2000 Enterprise Manager, it was very easy to generate a separate script file for each object but in SQL Server 2005 Management Studio it was removed without any reason from Microsoft. It was quite a big step backward in terms of User Experience because of the usability and popularity of this feature. [...]

Track object structure change without any trigger

Sometimes we need to monitor when the table structure or the stored procedure was last modified but we cannot use Triggers firstly because they are not applicable for strored procedures and secondly may be our enviornment does not allow for that e.g. in production systems. SQL Server 2005 provides you an excellent way to find [...]

Removing a column does not change the size of the table

Guess what happens to the size of the table if you drop one or more columns from the table? Will that table take less space? Many of us will say yes, offcourse! Wrong!!! The fact is that removing a column from the table does not change the physical size of the table. It looks strange [...]

How to find how much space is used by a table?

Many of us sometimes need to know the space used by a table. You can use sp_spaceused stored procedure for this. It returns excellent information like rows, space used by data and available space or unused space. It takes two parameters

Object Name i.e. Table,Indexed View or Service Broker Queue
UpdateUsage (optional flag)

Second parameter is only available [...]

Why SQL Server is better than Oracle?

May be you don’t agree with the title of this blog, but today I just want to share some facts and figures with you so that you can decide yourself. Some of these facts are from my own experience and others are from relevant sources which I will mention as appropriate.
First thing first, data is [...]

Multiple Groups in a single TSQL Query

Today’s dashboard applications require you to aggregate data based on different groups. Data warehousing tasks also require aggregates on different dimensions like Per Country total Qty, Per product Total Qty, Per country per product Total qty.
SQL Server 2000 or SQL Server 2005 does not allow you to create different sets of group in a single [...]

Remove Duplicates and clean your data quickly

Common Table Expressions addresses many issues which were previously either very difficult to resolve or sometimes even impossible in TSQL without using Cursors etc.
One of those issues was to delete all duplicates rows which were inserted into the table due to incorrect import  of data. Following script gives you an handy trick to remove all [...]