Description
Returns the core company name, by removing all punctuation, any leading "The" , and key words such as Corp, Inc, etc.
Syntax
STRIPCOMPANY ( TextSourceField )
Parameter | Description |
---|---|
TextSourceField | The string containing the company name. |
Remarks
See the table below for the list of words that will be removed by the function.
Doctor |
Dr |
The |
Agency | Gmbh | PA |
and | Group | PC |
Assn | Hotel | Pharmacy |
Assoc | Hotels | PLC |
Associates | Inc | PLLC |
Association | Incorporated | Restaurant |
Bank | International | SA |
BV | Intl | Sales |
Co | Limited | Service |
Comp | LLC | Services |
Company | LLP | Store |
Corp | LP | Svcs |
Corporation | Ltd | Travel |
DMD | Manufacturing | Unlimited |
Enterprises | Mfg |
Examples
This function returns "Joseph Joseph":
STRIPCOMPANY("The Joseph & Joseph Corporation")
This function returns "TeleTronics":
STRIPCOMPANY("TeleTronics Co., Inc.")
How it works
The STRIPCOMPANY function returns the root company name by removing certain punctuation, extra spaces, any leading "The", and key words such as Corp. and Inc. The function processes the company name in several passes to remove these characters and return the root company name.
The function algorithm is as follows:
If the word is in the company prefix list, the word is deleted from the string. If the word is not in the company prefix list, the word is put back into the string with no leading space and without its delimiter.
If the word is in the company suffix list, the word is deleted from the string. If the word is not in the company suffix list, the word is put back into the string with a leading space and without its delimiter.
Because of the way that a word is defined and the way the string is rebuilt from the words, one word at a time — without the delimiters, extra spaces, commas, and ampersands — is stripped out of the string.
The end result will be a string that has had commas, extra spaces, ampersands, apostrophes, dashes, and periods removed. It has also had company prefixes and company suffixes removed.
Note: Suffixes will be removed from anywhere in the string.
See also