Generating PIVOT/CROSS-TAB queries is one of the common requirements that we find in our day-to-day programming life. SQL Server 2005 introduced a new operator: PIVOT, which made generating pivot/cross-tab results much easier. Though the PIVOT operator...