From the course: Excel: Power Query (Get & Transform)

Unlock the full course today

Join today to access over 23,100 courses taught by industry experts.

Add column by example

Add column by example

Check out this data. We have first name, last name, phone extensions, favorite colors, and each person's mentor. Now, we're going to go into Power Query and work on this data so that I can show you column by example. The cursor is in the dataset. Right-click, from Table/Range, table does have headers. Okay. Now, let's say we want to create some name badges and we want everybody's first name all caps and the last, initial. Add column, Column From Example. Let's see. I want JAMES all caps and then A. Enter. Oh, check it out. We've got TOUSSAINT A. That's not what we want. RICARDO A. Let's give it another example. EVAN C., enter. Now, ELVIS H., yep, for Hawkins, Abner McCray. Scroll down. ELI T. Yep. Column by example got us what we want. And now notice up top, Power Query is writing a formula for us. Is doing TextCombine, then TextUpper. Meaning, all right, in the first name column we want all caps, then a space, that's the double quote space double quote, last name, but TextStart…

Contents