In my opinion, you should not do processing in the excel buffer table. The the grouping first before Inserting into the excel buffer table. Leave the excel buffer table only for expecting to excel.
Agreeing with Jordi79. For grouping in code, you need to create a table. It can be outside the licence range because you will be only using it as a temporary table. You create like 5 Code20 fields which will be the primary key, all of them, then like 10 decimal, 3 date, 3 text fields or something. In your code, you look up if the e.g. item no. exists in the first code field, if yes, add the values to the decimal fields, if not, you insert a new line.
... least this was the oldschool way of doing it and I think they added queries for this reason, so check them out.
Answers
I assume this was meant to export to excel?
... least this was the oldschool way of doing it and I think they added queries for this reason, so check them out.