This post has already been read 1231 times!
Simple Way To Use Pivot In SQL Query
This post intends to help T-SQL developers get started with PIVOT queries. Most business applications will need some sort of PIVOT queries and I am sure many of you must have come across pivoting requirements several times in the past.
Let us have a table name
Invoice which has three properties,
InvoiceAmount. Suppose we have several rows input in the table. Our goal is to display the sum of
InvoiceAmount each month.