Access offers you the capacity to work with enormous quantities of data, which means it can be challenging to learn anything about your database just by glancing at it. Sorting and filtering room two devices that let girlfriend customize exactly how you organize and view your data, do it much more convenient to work-related with. In this lesson, you'll learn just how to sort and also filter records.

You are watching: The field or fields on which the records are sorted

Throughout this tutorial, we will certainly be using a sample database. If you would favor to follow along, you'll should download our access 2016 sample database. You will should have accessibility 2016 mounted on your computer in bespeak to open up the example.

Watch the video below to learn more about sorting and also filtering documents in Access.

About sorting and also filtering

Essentially, sorting and also filtering are tools that let friend organize your data. As soon as you kind data, you room putting it in order. Filtering data allows you hide not important data and focus just on the data you're interested in.

Sorting records

When you sort records, you are placing them right into a logical order, v similar data group together. Together a result, sorted data is often easier to read and understand 보다 unsorted data. By default, access sorts documents by your ID numbers. However, there are many other ways records deserve to be sorted. For example, the information in a database belonging come a bakery can be sorted in a variety of ways:

Orders might be sorted by order date or by the last name that the customers who put the orders.Customers might be sorted through name or by the city or zip code where they live.Products might be sorted through name, category (like pies, cakes, and also cupcakes), or price.

You deserve to sort both text and numbers in two ways: in ascending order and descending order. Ascending way going up, for this reason an ascending sort will arrange number from smallest to largest and also text from A come Z. Descending way going down, or largest come smallest because that numbers and also Z to A because that text. The default i would number type that shows up in her tables is one ascending sort, i beg your pardon is why the lowest ID numbers appear first.

In our example, we will be performing a sort on a table. However, you can sort documents in any access object. The proccentregalilee.comre is largely the same.

To type records:Select a ar you want to type by. In this example, us will kind by customers' critical names.

Click the Home tab on the Ribbon, and locate the Sort & Filter group.Sort the ar by choosing the Ascending or Descending command.



After you conserve the sort, the records will continue to be sorted this method until girlfriend perform another sort or remove the present one. To remove a sort, click the Remove Sort command.


Filtering records

Filters permit you to see only the data you want to see. As soon as you develop a filter, you collection criteria because that the data you want to display. The filter then searches every one of the records in the table, find the ones that accomplish your find criteria, and also temporarily hides the ones the don't.

Filters room useful because they enable you to focus in on details records without being distracted by the data you're uninterested in. For instance, if you had a database that consisted of customer and also order information, you can create a filter to display screen only customers living in ~ a certain city or just orders include a particular product. City hall this data v a filter would be far much more convenient than in search of it in a big table.

In our examples and also explanations, we will be applying filters come tables. However, friend can use filters to any access object. The proccentregalilee.comre is largely the same.

To create a straightforward filter:Click the drop-down arrow next to the ar you desire to filter by. We will filter by city because we want to check out a perform of customers who live in a specific city.
A drop-down menu with a checklist will certainly appear. Just checked items will certainly be included in the filtered results. Click Select All will pick or deselect every little thing at once. In our example, we'll deselect everything except Cary.
Click OK. The filter will be applied. Our customers table now screens only customers who live in Cary.

Toggling her filter allows you to rotate it on and off. To see the documents without the filter, click the Toggle Filter command. To regain the filter, click the again.

Creating a filter indigenous a selection

Filtering by selection permits you come select certain data from her table and also find data that is similar or dissimilar come it. Because that instance, if you were working through a bakery's database and wanted to search for all commodities whose names included the native chocolate, girlfriend could pick that native in one product name and also create a filter through that selection. Producing a filter v a selection can be much more convenient than setup up a straightforward filter if the field you're working with includes many items. You can select from the complying with options:

Contains includes just records through cells the contain the selected data.Does no Contain consists of all records except because that those with cells that contain the selected data.Ends through includes only records who data because that the selected ar ends v the find term.Does Not finish With includes all records except because that those who data because that the selected ar ends with the find term.To create a filter indigenous a selection:Select the cabinet or data you desire to create a filter with. We want to see a list of all of our products that contain words chocolate in their names, so we'll pick the indigenous Chocolate in the Product Name field.
Select the Home tab ~ above the Ribbon, situate the Sort & Filter group, and also click the Selection drop-down arrow.
Select the type of filter you want to apply. We'll pick Contains "Chocolate" since we desire to see documents that contain words Chocolate almost everywhere in the field.
The filter will certainly be applied. Our table now display screens only commodities with the word Chocolate in your names.

Creating a filter native a find term

You can likewise create a filter by start a find term and specifying the means Access should complement data to the term. Creating a filter from a search term is similar to creating a filter native a selection.

Filtering message by a find term

When filtering message by start a find term, you have the right to use several of the same alternatives you use when filtering through a selection, like Contains, Does no Contain, Ends With, and Does Not end With. You can additionally choose from the adhering to options:

Equals, which has only documents with data the is similar to the selected dataDoes no Equal, which has all records except for the data the is the same to the selectionBegins With, which contains only documents whose data because that the selected field begins v the find termDoes Not begin With, which includes all records except for those whose data for the selected field begins with the find termTo filter message by a find term:Click the drop-down arrow beside the field you desire to filter by. We want to filter the records in our orders table to display screen only those the contain note with certain information, therefore we'll click the arrowhead in the Notes field.
In the drop-down menu, hover your mouse over Text Filters. Indigenous the list the appears, pick the way you desire the filter to match the term friend enter. In this example, we want to view only records who notes suggest the stimulate was put for a party. We'll select Contains so we can search for records that contain words party.
Filtering numbers with a search term

The process for filtering numbers with a find term is comparable to the procedure for filtering text. However, various filtering choices are available to you as soon as working v numbers. In addition to Equals and Does not Equal, you can choose:

Greater Than to encompass only records with number in that ar that space greater than or same to the number you enterLess Than to encompass only records with number in that ar that room less than or same to the number girlfriend enterBetween to incorporate records with numbers that loss within a details rangeTo filter number by a search term:Click the drop-down arrow beside the field you desire to filter by. We want to filter the documents in our food selection items table by price, for this reason we'll click the arrow in the Price field.In the drop-down menu, hover your mouse over Number Filters. Native the list the appears, select the method you desire the filter to complement your search term. In this example, we desire to view items that are less than $5, for this reason we'll pick Less Than.
The Custom Filter dialog box will appear. Kind the number or numbers you want to use in her filter. We'll type 5 therefore the filter will display us only menu items that expense $5 or less.

See more: New Jersey To Columbus Ohio Train, Amtrak Tickets, Schedules And Train Routes


Open the query dubbed Cakes and Pies Sold.Apply a filter to the Product varieties field that shows only Cakes.In the Sum the Quantity field, use a number filter that just shows number greater 보다 or equal to five.Apply one ascending sort to the Sum the Quantity field.