I'm sure this is simple for some...but pivot table have always confused me. This should be very simple...and yet it seems to be so hard to find an actual simple explanation on the web LOL.
I have the following temp table with this schema/data. I just need to pivot with no aggregation on the INT rows
CREATE Table #tempTable
(
Place VARCHAR(2),
First1 INT,
Second1 INT
)
INSERT INTO #tempTable (Place,First1,Second1)
values ('A1',1,8),('A2',2,5),('B1',4,6),('B2',3,7)
SELECT * from #tempTable
From this:
Place First1 Second1
A1 1 8
A2 2 5
B1 4 6
B2 3 7
To this:
A1 A2 B1 B2
First1 1 2 4 3
Second1 8 5 6 7
Thanks so much