Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chriss Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Display a string part containing delimiters

Status
Not open for further replies.

Buckaroo8

Programmer
Aug 6, 2003
27
US
Hi All,
I have location names in a format with consistent delimiters, but varied names sizes.
Example:

ABC-111-DEF-1
ABC-22-DEF-2

The point is how to eliminate everything on the left of the the 1st (or leftmost) hyphen '-', including the hyphen itself, despite the varied lengths.

i.e.
ABC-111-DEF-1 > 111-DEF-1
ABC-22-DEF-2 > 22-DEF-2

Al help is welcome and greatly appreciated!!!
 
Here's the first thing that comes to mind:

Mid({Table.Field}, Instr({Table.Field},"-") + 1)

-dave
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top