Calculated fields and totals rows let you perform calculations with the data in your tables. Calculated fields perform calculations using data within one record, while totals rows perform a calculation on an entire field of data.
When you create a calculated field, you are adding a new field in which every row contains a calculation involving other numerical fields in that row. To do this, you must enter a mathematical expression, which is made up of field names in your table and mathematical symbols. You don't need to know too much about math or expression building to create a useful calculated field. In fact, you can write robust expressions using only grade-school math. For instance, you could:
To find the total number of brownies that have been sold, we'll have to multiply the number of units sold by the numerical value of that unit—here, 2*12, which equals 24. This was a simple problem, but performing that calculation for each row of the table would be tedious and time consuming. Instead, we can create a calculated field that shows the product of these two fields multiplied together on every row.
To create a calculated field:
For more examples of mathematical expressions that can be used to create calculated fields, review the Arithmetic Expressions in the Expression Builder dialog box.Arithmetic operators in the Expression Builder
The totals row adds up an entire column of numbers, just like in a ledger or on a receipt. The resulting sum appears in a special row at the bottom of your table.
For our example, we'll add a totals row to our calculated field. This will show us the total number of items sold.
To create a totals row:
by Avantix Learning Team | Updated October 14, 2022
Applies to: Microsoft® Access® 2010, 2013, 2016, 2019, 2022 and 365 (Windows)
You can create calculated fields in select queries in Microsoft Access in the QBE (query by example) grid. You'll need to learn a few syntax rules and then you can create simple to more complex calculations. Calculated fields can also be created in other types of Access queries.
Recommended article: 10 Microsoft Access Tips for Working with Select Queries
Create a calculated field in a select query
To create a select query with a calculated field (which would appear in each record in Datasheet View):
In order for these calculations to work, the fields that you include in the expression should be fields in the displayed tables. Also, watch out for typing errors. Actual Sales is different from ActualSales and square brackets, not round brackets, are used to enclose the fields.
Below is the Zoom dialog box:
A calculated field in Design View in a query may appear in the Field row as follows:
These calculations are not case sensitive so you could also enter:
Create a calculated field using the Expression Builder
To create a query with a calculated field using the Expression Builder:
Below is the Expression Builder:
You can create all kinds of basic and more complex calculations using the functions in Microsoft Access not only in queries, but in forms, reports and other objects. We'll be showing some of the other calculations you can create in future articles.
Subscribe to get more articles like this one
Did you find this article helpful? If you would like to receive new articles, JOIN our email list.
Key Features and Benefits of Microsoft Access
How to Filter a Report on the Fly in Microsoft Access
10 Tips for Creating Select Queries in Microsoft Access
10 Techniques for Designing Forms in Microsoft Access
How to Convert a Microsoft Access Report to PDF (3 Ways)
Microsoft Access: Introduction
Microsoft Access: Intermediate / Advanced
Microsoft Access: Introduction to VBA (Visual Basic for Applications)
VIEW MORE COURSES >
Our instructor-led courses are delivered in virtual classroom format or at our downtown Toronto location at 18 King Street East, Suite 1400, Toronto, Ontario, Canada (some in-person classroom courses may also be delivered at an alternate downtown Toronto location). Contact us at if you'd like to arrange custom instructor-led virtual classroom or onsite training on a date that's convenient for you.
Copyright 2022 Avantix® Learning
Microsoft, the Microsoft logo, Microsoft Office and related Microsoft applications and logos are registered trademarks of Microsoft Corporation in Canada, US and other countries. All other trademarks are the property of the registered owners.
Avantix Learning |18 King Street East, Suite 1400, Toronto, Ontario, Canada M5C 1C4 | Contact us at