Link to home
Start Free TrialLog in
Avatar of Murray Brown
Murray BrownFlag for United Kingdom of Great Britain and Northern Ireland

asked on

ASP.net VB.net SQL - query issue

Hi

I have a GridView on my ASP.net web form  with the SQL table shown in the following image bound to it. I need to get the data into the format in the second image. What SQL or technique would I use to do this. The second image doesn't show the X values but I plan to show them there:

User generated image
User generated image
Avatar of PortletPaul
PortletPaul
Flag of Australia image

In SQL that would be termed a "pivot", and it can be achieved using SQL

Is the number of columns always the same?
or are you expecting the number of columns to increase/decrease?
Avatar of Murray Brown

ASKER

Hi
The number of columns changes
ASKER CERTIFIED SOLUTION
Avatar of PortletPaul
PortletPaul
Flag of Australia image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Thanks for the help