Click here to Skip to main content
15,920,468 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
This is AREA TABLE
http://img526.imageshack.us/i/65034019.jpg/[^]

PRODUCT TABLE
http://img14.imageshack.us/i/29732390.jpg/[^]

I want to load data as the image below
http://img38.imageshack.us/i/94684401.jpg/[^]

Please help me!
PS: sorry, i can't upload my image
Posted
Updated 26-Jun-10 19:46pm
v2
Comments
Sandeep Mewara 27-Jun-10 2:28am    
In case, you dont get an email, i dropped a comment to what you asked me in response to my answer.

1 solution

"I want to load data as the image below..."

So what is the problem? You have Area tables and Product tables in your database. Form a query.
Use the link that connects area & product. Query result can be formed in needed order. Fecth the query result in a dataset/datatable and bind it with a grid.

Try it!
 
Share this answer
 
Comments
khocmedemmua 27-Jun-10 2:10am    
Sandeep Mewara,
I want to load ProductID into the column header and AreaID into gridview as the following image
http://img38.imageshack.us/i/94684401.jpg/
I don't know how to do this ? Can you help me ?
thanks
Sandeep Mewara 27-Jun-10 2:28am    
You just want to load Product ID's columnwise and AreaID's row-wise. A simple query result in that format should do that for you. Currently the Product, Area tables in images uploaded by you don't show any link. I thought u have. Now it looks like you dont have it now. Design your database properly. Have a foreign key in table such that both are connected to each other in some way - then only you can store/show data in that format.

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