Easy-to-follow video tutorials help you learn software, creative, and business skills.Become a member
When you're trying to use filtering on multiple columns involving multiple criteria, the standard filter just doesn't work some of the time. We need to use an advanced filter. Suppose in the data here comprised of about 700 rows, we need to see people from a certain department who are full time and we also want to see people from another department who are half- time. And you can imagine some other combinations like that. What we need to do is set up a criteria range, so let's highlight the first six rows, put this above the data, insert, and simply copy the top row here, holding down the Control key drag this upward.
Let's just pick some departments here, for example ADC. Rather than typing this, I am just going to copy this up here. We would like to see out of the ADC department, the full time people. There are two of them. Once again to save myself some typing here, something with the Ctrl key I am going to drag this here. We are also interested in getting and seeing people from the Engineering/ Maintenance group. So once again saving ourselves some typing, holding down the Ctrl key. This. And here we are interested in seeing from that group the half-time people, so I will just copy this.
As a criteria range, this list here first of all does ignore columns D and E. If we use the Advanced Filter on the data, starting at row 7, what we are saying in English is let's see all records where the department is ADC and Full Time, in other words that combination together, or if we have got a combination of Engineering/Maintenance and Half-Time. That's what this criteria range means. So clicking anywhere in the data, using the Advanced Filter, here is our list range, totally accurate, criteria range, click here, scroll upward, select just these cells here.
So the ADC Full-Time people, Engineering/ Maintenance Half-Time people. Click OK. Any record we see here meets the two criteria, either this combination or this combination. So another way to read this is as we read left to right we are using the word And, those who were in the Department ADC and whose status is Full-Time, or those people in Engineering/ Maintenance who are Half-Time.
And you can imagine different combinations here. And you can come up with almost any kind of combination imaginable, the more you work with these. Now, if were to put Engineering/ Maintenance here and this were the criteria range, that would be very unusual and highly unlikely what it would mean is let's see all records where we either have a combination of these two criteria or anybody who's Half-Time or anybody who's Engineering/Maintenance. So even it wouldn't do that probably, it's doable and if you're familiar with the Access query grid, this would help because you understand in a same kind of way that's done.
But there's another use for an advanced filter to not quite so obvious. And that's, for example, if we wanted to use a function on one of our fields. For example suppose we wanted to find all the people hired on Monday. I think if I that were a sale day perhaps it would be more pertinent. How would we come up with this kind of construction? And there's no standard way to do this otherwise. The following formula is our starting point. Equal and I'm going to type in here g8. What does that mean? That's the first cell in the list that has a higher date in it. We are not seeing it currently because the other filter is in place unless we use it here. =g8.
Now we want to find out if these people were hired on Monday. You would need to know that here's a function called weekday and if the weekday of g8, meaning the first cell that has a date, =2. If you are familiar with the weekday function, 1 is Sunday, 2 is Monday etc. Now, to make this a little more readable let's go into our data and clear the filter, bring back all the data. So here is the data. And the reason this says false right here is the literally that very first entry there is not a Monday.
I don't care what it is really, but it's not a Monday. Now here is what we are about to do. We are going to use the Advanced Filter and use these two cells as the criteria range. Now without any knowledge of why this doesn't work, I'm going to remove this word here and we must do this, this phrase, Hire Date. This will be the criteria range and we will see just the people hired on Mondays. So with the active cell within our data, we use the Advanced Filter.
The criteria range is not what it had been. It is now going to be just these two cells and this will not work if you leave data in cell G1, so that has to go. And here is the criterion that we put in earlier and click OK. And there are 112 of these records. These are all Mondays. You could do a quick test on one of these simply by typing equal weekday, left parenthesis. Click on one of these dates. The answer will be 2, because its a Monday and that's a Monday also and so on.
So pretty far away from being intuitive. I have never even come close to calling at that, but another use of the Advanced Filter for unusual situations which you cannot get to with the regular filter.
Get unlimited access to all courses for just $25/month.Become a member
82 Video lessons · 90657 Viewers
80 Video lessons · 137961 Viewers
59 Video lessons · 56726 Viewers
52 Video lessons · 70339 Viewers
Access exercise files from a button right under the course name.
Search within course videos and transcripts, and jump right to the results.
Remove icons showing you already watched videos if you want to start over.
Make the video wide, narrow, full-screen, or pop the player out of the page into its own window.
Click on text in the transcript to jump to that spot in the video. As the video plays, the relevant spot in the transcript will be highlighted.