A Beginner's Guide On AdvanceFilter
We use the AdvanceFilter function when we want to filter our data in the data area (database) based on more than one column title. If we want to filter our data in the data area (database) based on one column title only, we use AutoFilter.
We can access the AdvanceFilter function by clicking on the menu Data/Filter/AdvanceFilter.
1. Valid Data Area
Before we use this function, we must have data in a proper data area (database). A data area is a rectangular area of adjacent cells boundaried by a row on top, a row at the bottom, a column on the left and a column on the right. Refer to topic 31 for more information on valid data areas.
2. Setting Criteria
When we want to use AdvanceFilter, we need to identify what columns titles (or data titles) we want to use as basis of filtering. We identify them by writing the relevant data titles in another area (preferably in other sheet). In that other sheet, we write the data titles in a separate cell in a row (any row) and must be adjacent to each other. In cells below each titles, write the item that we want to see as a result of the filtering. (It could be more than one cell filled with item under each title). The item must be one that is actually available in cells below that title in the actual data area.
The area where we write the selected data titles and the selected items below it is called a CRITERIA. Let's take a look at a few simple examples:
Example 1:
A B 1 Title A Title B 2 xxxx yyyy 3
This criteria means we want to see rows where each row has item 'xxxx' below a data title A and has item 'yyyy' below data title B. Only rows having these 2 items will be selected, the rest will be hidden.
246
Example 2
A B 1 Title A Title B 2 xxxx 3
This means we want to see rows where each row has item 'xxxx' below a data title A and has any other item under data title B. Only rows having item 'xxxx' under title A will be selected (Cells under title B can contain anything). The rest will be hidden.
Example 3:
A B 1 Title A Title B 2 XXX yyyy 3 aa 4
This means we want to see rows where each row has item 'xxx' below a data title A and has item 'yyyy' below data title B, and also each row which has item 'aa' below a data title A and has any other item below data title B. Only rows satisfying these conditions will be selected. The rest will be hidden.
Example 4:
A B 1 Title A Title B 2 xxxx 3 aa yyyy 4
247
This means we want to see rows where each row has item "sooox' bellow a dasta title A and has any item below data title B, and also each row which has item 'aa' below a data title A and has item 'yyyy below data title B. Only rows satisfying these conditions will get selected. The rest will be hidden.
Example 5:
A B 1 Title A Title B 2 XXX 3 aa yyyy 4
This means we want to see rows where each row has item 'xxx' below a data title B and has any item below data title A and also each row which has item 'aa' below a data title A and has item 'yyyy' below data title B. Only rows satisfying these conditions will get selected. The rest will be hidden.
Example 6:
A B 1 Title A Title B 2 xxxx 3 yyyy 4
This means we want to see rows where each row has item "xxxx below a data title A and has any item below data title B and also rows which each row which has item "yyyy below a data title B and has any item below data title B. Only rows satisfying these conditions will get selected. The rest will be hidden.
By now, you would see that a blank cell in the 'Criteria' block represents ANY. A row in the Criteria represents a row in the actual data area.
248
3. Use AdvanceFilter
After you set the Criteria then you can start using the menu Data/Filter/AdvanceFilter. You can set more than one Criteria in one sheet to serve different filtering.
1. After the Criteria is ready, activate the sheet which contains the data you want to filter.
2. Click menu Data/Filter/AdvanceFilter. You will see the Advance Filter dialog box.
3. On the right of the List range label is your data area automatically identified by Excel. (Check this range. If it is incorrect, click Cancel, correct you data setting, and start again).
4. Click on the Criteria range box. Click at the sheet where the criteria that you want to use reside. Select the criteria range. Automatically the Criteria range box will be filled with the address of your selection area (criteria range).
5. Click OK. Your data in the data area will get filtered accordingly (You see only data that you want to see).
Summary
To filter data based on one item in one column, use AutoFilter operation.
To filter data based on more than one item from one column, use Custon in the AutoFilter menu.
To filter data based on more than one item from more than one column, use AdvanceFilter operation.
249