Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsFree MagazinesWhite PapersSubmit Content
Discussion GroupsASP.NETWindows FormsLanguages.NET FrameworkVisual Studio.NET
Articles.NET FrameworkASP.NETToolsWindows Forms
.NET DirectoryOpen Source ProjectsUser GroupsWeb Resources
Related Topics
Visual Basic 6SQL ServerMS AccessOther DB ProductsMS Server ProductsMore Topics ...

.NET Forum / ASP.NET / DataGrid / November 2006

Tip: Looking for answers? Try searching our database.

Formatting result from a database query

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Mathias - 21 Nov 2006 18:40 GMT
From my database query I get the following:

Text Number
Albert 12
Albert 14
Albert 16
Brian 20
Brian 21
Brian 22

Now I'd like to represent the data as:

Albert 12 14 16
Brian 20 21 22

I've looked at repeaters, data sets, data readers but I can't figure
out how to go about it. Preferably I'd like to represent the data in a
GridView. Can anyone please guide me in the right direction? :)
Eliyahu Goldin - 22 Nov 2006 14:44 GMT
The easiest solution is to build programmatically a new datatable containing
one row per name out of the original result set and databind the gridview to
the new table.

Signature

Eliyahu Goldin,
Software Developer & Consultant
Microsoft MVP [ASP.NET]

> From my database query I get the following:
>
[quoted text clipped - 14 lines]
> out how to go about it. Preferably I'd like to represent the data in a
> GridView. Can anyone please guide me in the right direction? :)

Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.