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 Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Round up and Truncate 1

Status
Not open for further replies.

PJOL

IS-IT--Management
Oct 11, 2005
28
0
0
IE
We have a report with a total that's not an actual field, i.e. it's a sum calculated from sub-totals from other fields. I need to round it up or truncate it in our favour, i.e. 5.1 rounded up to 6 and so on. There is a formula for this in Crystal for fields, but I'm having difficulty applying it to a sum total. Any help appreciated.
 
You should always share contents of your formulas. Anyway, create a formula like this:

-int(-{@yoursummary})

Use this instead of {@yoursummary}.

-LB
 
The output I want to truncate is a Sum field object as follows:

Sum of @UOM GI (number)

The @UOM GI (number) is a conversion formula as follows:

{PLANNING_JOB_STAGE_LINES.INPUT_QTY_STD_BATCH}/{PART_UOM_CONVERSIONS.UOM_CONVERSION_FACTOR}

 
Then the formula would be:

-int(-sum({@UOM GI})) //if the sum is a grand total, or

-int(-sum({@UOM GI},{table.groupfield}))//if it is a group total

-LB
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top