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 strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

split or extract numeric characters from column

Status
Not open for further replies.

2Plan

MIS
Mar 29, 2005
55
US
Is there a way I can get just the numbers of this column in a separate column by itself, so I can sort the data?


1-NORTH LAMAR/SOUTH CONGRESS
10-SOUTH 1ST/RED RIVER
17-CESAR CHAVEZ
2-ROSEWOOD
20-MANOR RD/RIVERSIDE
201-SOUTHPARK MEADOWS
21-EXPOSITION
22-CHICON
3-BURNET/MANCHACA
30-BARTON CREEK SQ
300-GOVALLE
311-STASSNEY
328-BEN WHITE
331-OLTORF
333-WILLIAM CANNON
350-AIRPORT BLVD
481-NIGHT OWL NORTH
482-NIGHT OWL EAST
483-NIGHT OWL SOUTHEAST
 
figured it out. text to column (delimter "-")

Thanks.
 
That's what I'd do - but for the sake of completeness I'll mention that you can also do this with a formula.

Given that you want everything to the left of the hyphen,

[COLOR=blue white]=left(A1, find("-", A1) - 1)[/color]

That will return the numeric characters, but they'll be returned as text strings. If you want to return them as numbers, just wrap the whole thing in Value():

[COLOR=blue white]=Value(left(A1, find("-", A1) - 1))[/color]

[tt][blue]-John[/blue][/tt]
[tab][red]The plural of anecdote is not data[/red]

Help us help you. Please read FAQ 181-2886 before posting.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top