Using a Formula to Perform a Basic Calculation

The report created above lists products with their unit price. Assume that this is the price that the bike shop (Customer Name) pays Extreme for the merchandise. You want to calculate the MSRP (manufacturer’s suggested re­tail price) of the different products if you marked the price up 35 percent. Yes, this report exists in a fantasy world where you only see a 35-percent markup.

To write this formula:

1.    Click Insert, formula Field to open the Formula Editor.

2.    With Formula Field selected, click the new button to open the For­mula Name dialog box. Enter the name MSRP for the formula. Click OK and the Formula Editor opens.

3.    Double-click the Order Detail. Unit Price field located in the Fields pane. This copies the field into the Formula Text pane, with the proper syntax (French braces {} around the field).

4.    Click the Arithmetic list in the Operators pane to expand and see your choices. Double-click the multiply sign to copy it to the For­mula Text pane.

5.    Type the numbers 1.35 from your keyboard after the multiply sign. Your formula should now look like the one pictured.

6.    Click the Check button. Hopefully you will get the message “No Errors Found.” You just wrote your first formula.

7.    Click the Save and Close button to save the formula and close the For­mula Editor. The formula now appears to the Field Explorer under the Formula Fields heading.

8.    Reinsert the formula field into the Details section of your report, to the right of the Unit Price field. Insert formula fields the same way you insert database fields. The formula name you entered appears as the column heading.

9.    Preview your report. Notice that the MSRP formula now looks and acts like any .other field on your report—and it has calculated the MSRP for each product ordered.

Facebook
Twitter
Pinterest