how do i convert reqular SELECT statement to Sql Server Pivot

Hello
I have a view as in image1 and would like make a view with PIVOT as in image 2.

Thanks
 Image 1 simple select Image 2 as Pivot
gabi456Asked:
Who is Participating?
 
JestersGrindCommented:
To do a pivot you need something to actually pivot on.  From the screenshot it doesn't appear that you have that.  Is there always exactly 2 records?  If so, you could do something like this to get the same effect.

SELECT NivdakID, MIN(Golmi), MAX(Golmi)
FROM YourTable
GROUP BY NivdakID

Greg

0
 
gabi456Author Commented:
Your a cool guy:)

Thanks.
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.