From the course: Excel: Power Query for Beginners

Unlock this course with a free trial

Join today to access over 24,400 courses taught by industry experts.

Conditional columns

Conditional columns

- [Instructor] I have lots of rows that represent sales transactions here, and each of the products are very specific. We've got apples, we have bananas, we've got broccoli and celery, we've got coffee. What if I want a higher level category breakdown? For example, what if I want to know the beverage sales versus the vegetable sales versus the fruit sales? It's almost like I need a new column here that tells me that category or department that the product belongs to. So let's add that column. We'll do that by adding a conditional column in Power Query. I've got the 0204 sales data file open, and I'm going to remove this to give myself some more room. And to add that column, I'm going to go to the data tab and then click get data, launch Power Query editor. And here we are in Power Query. I'm going to click add column at the top and choose conditional column. So I'm making a new column. The column's going to be called category for the category of product or department of the product…

Contents