Customizing a data view / Response.Write

  • Thread starter Thread starter anony
  • Start date Start date
A

anony

What is the desired way to deliver a customized view of a database query?
The scenario is that I want to group records based on similar fields. Can I
use any built in data controls and achieve this level of customization? I
can accomplish my custom view via Response.Write, but this can't be the way
to go, for no other reason than it dumps out HTML prior to the <HTML> tag.
For example:



The data:



MAINGROUP SUBGROUP RECNO

--------- -------- -----

Dogs Labrador 1000

Dogs Labrador 1001

Dogs Labrador 1002

Dogs Schnauzer 1003

Dogs Schnauzer 1004

Dogs Poodle 1005

Mouse Mickey 1006

Cats Siamese 1007

Cats Siamese 1008

Cats Siberian 1009

Cats Siberian 1010





Desired View:



Animal Breed Details

------ ----- -------

Dogs Labrador 1000, 1001, 1002

Schnauzer 1003, 1004

Poodle 1005

Mouse Mickey 1006

Cats Siamese 1007, 1008

Siberian 1009, 1010





Thanks for any advice.

Brian
 
Why not create a new datatable in the dataset, loop through the datatable
you got and insert summary rows into new datatable, then bind the new
datatable to DataGrid, DataList,......
 
Back
Top