Crystal Reports for Eclipse Designer Guide

FinalFormula

  1. Create a new formula called FinalFormula.
  2. Select the Formula tab in the Crystal Reports Designer and type the following formula:
    If ({CUSTOMER.CUSTOMER_NAME} [1 to 2] = "Bi" and
    ToText({CUSTOMER.CUSTOMER ID}) [1] = "6") or
    ({CUSTOMER.CUSTOMER_NAME} [1 to 2] = "Ro" and
    ToText({CUSTOMER.CUSTOMER ID}) [1] = "5") Then
         "PREFERRED CUSTOMER"
    Else
         "DOES NOT FIT CRITERIA"
    
  3. Save the report.
  4. Click the Preview tab.
  5. Check the values in the report and compare the fields to see if the field values returned by @FinalFormula are correct.
    You should see "PREFERRED CUSTOMER" next to the customers whose names begin with "Bi" and IDs begin with 6, or the customers whose names begin with "Ro" and IDs begin with 5. You should see "DOES NOT FIT CRITERIA" next to all the Customer IDs that do not meet this criteria.
You can use this same process of condition-by-condition testing for any formulas as a means of systematically checking them.



SAP BusinessObjects
http://www.sap.com/sapbusinessobjects/
Support services
http://service.sap.com/bosap-support/
Product Documentation on the Web
http://help.sap.com/