Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Westi on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

total problem 1

Status
Not open for further replies.

ajdesigns

Technical User
Jan 26, 2001
154
GB
Hi
I am running CR 8.5, and I am having touble totaling lines in a sales order.
Each sales order contains a number of lines (items)this is no problem to total the total cost of the order by saying qty ordered *price this gives me the total price of the order.
But if we used 2 different lot numbers to complete one of the order lines, then this doubles the qty ordered and so gives double the actual price for that line.
 
Use the running total expert. Assuming that you have a detail level formula {@cost} like:

{table.qty}*{table.price}

...then select {@cost} as the field to summarize in the running total, sum, evaluate on change of group (table.itemID}, reset on change of group (table.orderID}.

In other words, you need a group on the Order ID and then a second group on the items in the order. If you count only once per item, the number of lots is irrelevant. The running total needs to be displayed in the group footer for Order ID, not the group header.

-LB
 
Brilliant
Thanks
I did have to evaluate on change of field and reset never, because I needed a grand total for all lines, but it works great.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top