PARSENAME

Description

Returns the specified name token from a name line.

Syntax

PARSENAME ( TextSourceField, "name_token" )

Parameter Description
TextSourceField The string from which to return a name token.
name_token The identifier for the name token to return. Use one of the following values:
  • P — Prefix
  • F — First name
  • M — Middle name
  • L — Last name
  • S — Suffix
  • D — Professional degree

Remarks

A valid name should include a first name and last name, and may also include a middle name, prefix, suffix or professional degree. Listed below are the prefixes, suffixes, and professional degrees the function recognizes.

 

Examples

This function returns John:

PARSENAME("Mr. John T. Smith Jr., PhD", "F")

This function returns Smith:

PARSENAME("John T Smith", "L")

See also

PARSE

PARSEADDR