D
Danny Ni
Hi,
Is there a way to insert summary rows into a dataset or datareader without
actually save them back to the SQL server?
I have a resultset returned by SQL server using the following SQL statement:
select gid, eid, wdate, whours from timelog order by gid, eid, wdate
I like to insert a summary row for every eid and gid.
For example, the following dataset or datareader:
gid eid wdate whours
------------------------------------
1 101 1/1/04 8
1 101 1/2/04 8
1 102 1/1/04 7.5
1 102 1/2/04 6.5
will become
gid eid wdate whours
------------------------------------
1 101 1/1/04 8
1 101 1/2/04 8
1 101 null 16
1 102 1/1/04 7.5
1 102 1/2/04 6.5
1 102 null 14
1 null null 20
Thanks in Advance
Is there a way to insert summary rows into a dataset or datareader without
actually save them back to the SQL server?
I have a resultset returned by SQL server using the following SQL statement:
select gid, eid, wdate, whours from timelog order by gid, eid, wdate
I like to insert a summary row for every eid and gid.
For example, the following dataset or datareader:
gid eid wdate whours
------------------------------------
1 101 1/1/04 8
1 101 1/2/04 8
1 102 1/1/04 7.5
1 102 1/2/04 6.5
will become
gid eid wdate whours
------------------------------------
1 101 1/1/04 8
1 101 1/2/04 8
1 101 null 16
1 102 1/1/04 7.5
1 102 1/2/04 6.5
1 102 null 14
1 null null 20
Thanks in Advance