transcript

excelisfun - Excel Magic Trick 1267: PivotTable Automatic Date Grouping: New in Excel 2016

Thumbnail of the video “excelisfun - Excel Magic Trick 1267: PivotTable Automatic Date Grouping: New in Excel 2016”
Download Markdown
Community upload. AI output has not been independently verified.

welcome to Excel magic number 1267. Hey, if you want to download this workbook, let's go, match to 1026 to 1216 and follow along. Click on a link below the video. Hey, we got to check out something new in Excel 2016: pivot tables automatically group dates. Now you're not going to believe this, and if you started using 2016 and you didn't read anything, this is disconcerting. In fact, this happened to me the first time I did a pivot table group date side. I thought it was going to have to group, but it did it automatically.

Let's click in a single cell, and our goal really is to roll up revenue into monthly reports. Now notice these dates: some of them are 17, some are 16. Ctrl+Down Arrow, so we have like 2000 records, all the different months from those two years. All right, we click in a single cell, insert pivot table, or we can use the keyboard Alt+V. I'm going to put it on this existing worksheet, the location, let's say F4, click OK, and here it is. Here is our field list, and right there at the top is Date. Hey, we're going to drag it down to Rows like we normally do before we group. Boom. Now, usually when we drag Date down to Rows, we get a unique list of all the individual dates. Now, if you actually want daily sales or revenue, you'd have to come over to the field and right-click Ungroup. Now remember, in earlier versions we had to right-click Group to get it into years, months, quarters, etc. You'd have to ungroup if you actually want daily sales. I'm going to Ctrl+Z.

Now notice over here in the Rows area, and I'm going to pull the middle up here. There it is: Years, Quarters, Date. And sure enough, up here we have Date, Quarters, and Years. Now Date is month. If we come over here, we can expand, there's the quarter, and there are the months. Now, if you didn't want quarters or years, you simply uncheck. In this case, this is probably not the report we want. We probably do want years. That's not exactly what I wanted, like Year and then all of the months. So I'm simply going to drag Year on top of Date.

Now I can drag Revenue down to Values, right-click, and use Number Formatting, not Format Cells. Number Formatting adds number formatting to the actual field from the table, the Revenue field. I'm going to say Currency, two decimal places, click OK. Now one thing that's interesting: if I go up to Design, Report Layout, and Tabular, it's going to throw the date right over with that name right there. I think I would change that to Month. I'm going to Ctrl+Z. M, leave it in Compact. If I leave it in Compact like this, I'm definitely not going to leave Row Labels. I'm going to name it something like Date and enter. And so there is our pivot table, and I expand this down there with automatic grouping in Excel 2016. All right, we'll see you next video.