O'Reilly logo

Hands-On Microsoft Access: A Practical Guide to Improving Your Access Skills by Bob Schneider

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Adding Calculated Fields

Queries give you the freedom to both retrieve records and manipulate them. Notably, you can add fields that display the results of a calculation on stored values.

Using an Arithmetic Expression

For example, suppose you were anticipating that purchase prices would rise uniformly for all products about 8%. You want to create a field that will show what the new prices will be for each product.

You've used expressions to set criteria; now you'll use one to create a calculated field.

1.
Select the tblMerchandise table in the Database window. Choose Insert, Query. With Design View selected, click OK.
2.
Add MerchName, MerchDescription, and PurchasePrice to the design grid.
3.
Click in the Field row of the fourth column.
4.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required