Removing Name - 1097 - Learn Excel from MrExcel Podcast

If you like this content, please consider visiting the video on YouTube and subscribe to the MrExcel Channel to show your support!
This video has been published on Sep 8, 2009.
Shift-Del sends in some alternative formulas to solve the problem from episode 1043. To see uses of SUBSTITUTE and REPLACE in Excel, check out Episode 1097.

This blog is the video podcast companion to the book, Learn Excel 97-2007 from MrExcel. Download a new two minute video every workday to learn one of the 377 tips from the book!
maxresdefault.jpg


Transcript of the video:
Hey, welcome back to the MrExcel netcast. I'm Bill Jelen.
Basically you start out with massive amounts of data.
So how we gonna analyze as well let's fire up a pivot table.
Lets see if you can solve this problem.
Hey all right, welcome back. It's another MrExcel netcast.
I'm Bill Jelen.
We're going to go back to episode 1043 . Back in episode 1043 I had this data with name in column A, name and address in column B, And I wrote this formula over here in column C.
To strip out the name from column B to get the address only, I used the MID function and the LEN function.
Someone at the MrExcel message board sign up there and they use the handle if shift+delete. So I don't know who they are where they're from, but they sent 4 cool formula variations to this and I like them.
So I'm going to cover them right here.
the SUBSTITUTE function.
Substitute says. Hey, we have some text here in B2 and within that text, I want you to find the name from A2 and substitute the name with nothing quote quote.
Check this out now the problem that we have is that that gives us a leading space because there's a space between company and 1292 and so the two suggestions one was to use the TRIM.
Function TRIM ofcourse removes leading and trailing spaces.
Solves our problem or instead of using TRIM we can get rid of TRIM and say. Hey, in the SUBSTITUTE function instead of looking for A3 we want to look for A3&" " and that will take care of it as well, so the substitute function very cool.
Another one is the REPLACE function.
REPLACE function says take the text from B, start at position one and go to the length of A1 for 1 and substitute that whole thing with "" and that gets rid of it as well and then finally using the right function, this is probably the most convoluted, how we will use the right of B5 and to figure out which right most characters we use, the length of all B5 minus the length of A5-1 So several different ways to go there.
You know I always say there's a couple of ways to solve every problem in excel.
Here's an example where 5 very cool functions and hey, shift+del.
Thanks for those great suggestions.
You send me your postal address, I'll send you one of my excel master pins.
Thanks for sending that in and thanks to you for stopping by.
Will see you next time for another netcast from MrExcel.
 

Forum statistics

Threads
1,213,556
Messages
6,114,284
Members
448,562
Latest member
Flashbond

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top