Hi,
Tharwn helped me with this but still can't get all of the elements down.
Here's what we have in concept:
1) SQL Query
2) Execute into RS
3) Declare a temporary variable to hold catagory (tempCat) and initialize to ""
3.5) declare runningTotal and set to 0
4) Do Until rs.eof
5) if tempCatagory <> rs("catagory"
then
a.5) if tempCat <> "" then output a row with total for last catagory
a) output the catagory
b) set the tempCat variable = rs("catagory"
6) output the record as usual
6.5) increment the total from whatever field in the recordset or increment by 1 for a recordcount in this catagory
7) rs.MoveNext
8) Loop
9) if tempCat <> "" then output a row with total for last catagory
Here's my actual result:
Cat A Record Counts
------ -------------
prod 1 500
prod 3 1000
====== =============
Total 1500
Cat B Record Counts
------ -------------
prod 5 2500
prod 8 41000
====== =============
Total 43500
I need help getting the "Cat A" Total line there. I have the very last Total okay. Please HELP!!!
Thanks,
Ricky Thanks,
Ricky Ombina
ombina@yahoo.com
Tharwn helped me with this but still can't get all of the elements down.
Here's what we have in concept:
1) SQL Query
2) Execute into RS
3) Declare a temporary variable to hold catagory (tempCat) and initialize to ""
3.5) declare runningTotal and set to 0
4) Do Until rs.eof
5) if tempCatagory <> rs("catagory"
a.5) if tempCat <> "" then output a row with total for last catagory
a) output the catagory
b) set the tempCat variable = rs("catagory"
6) output the record as usual
6.5) increment the total from whatever field in the recordset or increment by 1 for a recordcount in this catagory
7) rs.MoveNext
8) Loop
9) if tempCat <> "" then output a row with total for last catagory
Here's my actual result:
Cat A Record Counts
------ -------------
prod 1 500
prod 3 1000
====== =============
Total 1500
Cat B Record Counts
------ -------------
prod 5 2500
prod 8 41000
====== =============
Total 43500
I need help getting the "Cat A" Total line there. I have the very last Total okay. Please HELP!!!
Thanks,
Ricky Thanks,
Ricky Ombina
ombina@yahoo.com