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!

Display last 4 chars of a column 1

Status
Not open for further replies.

load3d

Programmer
Feb 27, 2008
117
US
I'm having a brain malfunction today.

I'm querying the telephone numbers and names out of Active Directory. I want the query to display only the last 4 digits of column two. IE. John W. Smith - 1234.

Example:
Column 1
John W. Smith
Column 2
555-555-1234
 
Use the RIGHT function.

Ex:

Select Right(Column2, 4) As WhateverAliasNameYouWantToUse

-George

"The great things about standards is that there are so many to choose from." - Fortune Cookie Wisdom
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top