We help IT Professionals succeed at work.

SQL Pivot table

135 Views
Last Modified: 2017-04-05
I'm trying to convert the following table

id      data
1      2
2      ServerABC
3      ClientA
4      ServerXYZ
5      ServerFGH
6      Duplicate

to look like this

DupeCnt  Server          InitialCatalog   DirectoryServer   IIS
2                ServerABC  ClientA              ServerXYZ             ServerFGH

I need to exclude 6 duplicate

Any help much appreciated
Comment
Watch Question

CERTIFIED EXPERT
Commented:
This problem has been solved!
(Unlock this solution with a 7-day Free Trial)
UNLOCK SOLUTION
Mauro CazabonnetSenior Windows Automation Developer
CERTIFIED EXPERT
Top Expert 2015

Author

Commented:
Thx!!!!!!