i want to get minimum of multiple summmerized crystal report fields
- User
i want to get minimum of multiple summmerized crystal report fields
- Assistant
To calculate the minimum value of multiple summarized Crystal Report fields, you can use the MIN function. Here's an example of how you can achieve this:
-
In your Crystal Report, create a formula field (let's call it "MinValue") to calculate the minimum value.
-
In the formula field editor, write the following formula:
codeMinimum ({Field1}, {Field2}, ..., {FieldN})Replace
{Field1},{Field2}, ...,{FieldN}with your actual field names to be considered for the minimum calculation. -
Save the formula field and add it to your report.
-
Run the report, and it will display the minimum value of the summarized fields.
Note: Make sure to adjust the formula and field names as per your specific requirements.
-
- User
there is an error when i type minimum(sum {Field1},sum {Field2})
- Assistant
Apologies for the confusion. To calculate the minimum of the summarized crystal report fields, you can use a combination of formulas and variables. Here's the revised approach:
-
In your Crystal Report, go to the "Report" menu and select "Selection Formulas" -> "Record" option.
-
In the selection formulas editor, write the following formula:
codenumVar minValue; minValue := Minimum({@Field1}, {@Field2}); True;Replace
{@Field1}and{@Field2}with the formula fields representing the summarized values. -
Save the selection formulas and click "OK" to exit.
-
Now, create a new formula field (let's call it "MinValue") to display the minimum value.
-
In the formula field editor, write the following formula:
code{@Field1} = minValue Or {@Field2} = minValue;This formula will only display the value when it matches the minimum value calculated in step 2.
-
Save the formula field and add it to your report.
-