Click here to Skip to main content
15,891,033 members
Please Sign up or sign in to vote.
1.00/5 (1 vote)
See more:
EX:I have a stored procedure like(select center,dept,sum(Amount) from table where distno=19);(note:I am selecting those columns from multiple tables using joins) wrote that single query for understanding.....

so when i bind it dynamically the gridview looks

centre dept amount

hyd IT 2500

hyd cse 2600

hyd ECE 2700

bangl IT 2200

bangl CSE 2300

bang ECE 2500 ----like so on......as i have some no of centers and dept(based on selected distrtict center and dept varies)

I want to bind gridview like

HTML
Center	        IT 	CSE 	ECE
--------------------------------------
Hyderabad	2500	2600	2700
Banglore	2700	2200	2300
--------------------------------------


...

How can i achieve this??(hope the question is understandable)
Posted
Updated 1-Jun-14 18:52pm
v2
Comments
[no name] 1-Jun-14 4:20am    
"hope the question is understandable", what question is it that you are referring to? There is no question or even a description of any kind of a problem in your posting anywhere.
agent_kruger 1-Jun-14 4:47am    
sir, the irony of the question is it is not understandable.
Prasad Avunoori 2-Jun-14 0:53am    
He wants to generate a pivot report.
Prasad Avunoori 2-Jun-14 0:54am    
Hi Raju,

Have a look at my solution below.

1 solution

 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900