I have a table with columns: col1, col2, col3
. The table has many rows.
Suppose that val1, val2, val3
is one such string. I want to get the result as
Col1, Val1 Col2, Val2 Col3, Val3
These are three rows β one for each column and its value.
I am using SQL Server 2008. I read about pivots. Are there reasons to solve this problem? Can someone direct me to some examples or solutions how to solve this problem?
thanks a lot
source share