By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
438,843 Members | 2,311 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 438,843 IT Pros & Developers. It's quick & easy.

columns operation

P: 13
Hi all,
Is there any way so that I can get data in a column as column headers for that table
Feb 19 '09 #1
Share this Question
Share on Google+
4 Replies


100+
P: 152
gpl
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
Feb 19 '09 #2

ck9663
Expert 2.5K+
P: 2,878
Or search PIVOT or UNPIVOT

-- CK
Feb 19 '09 #3

P: 13
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
Feb 20 '09 #4

ck9663
Expert 2.5K+
P: 2,878
You might be able to get away by building your T-SQL dynamically.

-- CK
Feb 20 '09 #5

Post your reply

Sign in to post your reply or Sign up for a free account.