Please help - query

amtak

New Member
Hi,

I am new to progress and have been experamenting with verious procedures
that i would like to use within our company. One that i am stuck on is creating
an export routine for customer orders. I can export the data ok, but what i want is to calculate the total cost of the order lines and export this figure with my order heading.

At the end i want to have a txt file that shows the heading for each order with the total of all lines for that order.

I think i wouuld have to create a temp tabel to put the data in and the export
that tabel, would that be right. I am not sure on how to do the calculation though. Any help anybody can give would be very much appreciated.

Thanks

James
 
hi, for calculating see
ACCUMULATE
ACCUM
LAST-OF.

Example calc from online-help (mark LAST-OF in the editor and press F1):
...
r-lastof.p:
FOR EACH item BREAK BY cat-page:
ACCUMULATE on-hand * price (TOTAL BY cat-page).
IF LAST-OF(cat-page)
THEN DISPLAY cat-page (ACCUM TOTAL BY cat-page
on-hand * price) LABEL "Value-oh".
END.
 
Back
Top