Connecting Tech Pros Worldwide Help | Site Map

columns operation

Newbie
 
Join Date: Feb 2008
Posts: 13
#1: Feb 19 '09
Hi all,
Is there any way so that I can get data in a column as column headers for that table
gpl gpl is offline
Member
 
Join Date: Jul 2007
Posts: 34
#2: Feb 19 '09

re: columns operation


It sounds like you are wanting to create a crosstab query (where for each value in a column you return a count) - if thats right, put crosstab into the search box at the top and you will find many posts about it.

If that isnt what you want, just say a little clearer what it is you want to do
ck9663's Avatar
Expert
 
Join Date: Jun 2007
Posts: 1,925
#3: Feb 19 '09

re: columns operation


Or search PIVOT or UNPIVOT

-- CK
Newbie
 
Join Date: Feb 2008
Posts: 13
#4: Feb 20 '09

re: columns operation


Thank u,
In case of using pivot we should initially declare the required item or column .
How can we read column dynamically at run time
ck9663's Avatar
Expert
 
Join Date: Jun 2007
Posts: 1,925
#5: Feb 20 '09

re: columns operation


You might be able to get away by building your T-SQL dynamically.

-- CK
Reply