There's no such thing as a stupid question, but they're the easiest to answer.
JoinTour
Login
 
Tag Cloud
acer black screen blue screen boot computer connection crash css dell drive driver drivers email error ethernet excel explorer firefox firefox 3 hard drive internet internet explorer itunes laptop linux malware monitor network networking outlook outlook 2003 outlook express password printer problem problems ram router security slow software sound trojan usb virus vista windows windows vista windows xp wireless
Software Development
Search
Search in:
 
Advanced Search
Tech Support Guy Forums > Software & Hardware > Software Development >
Crystal Reports


HELLO AND WELCOME! Before you can post your question, you'll have to register -- it's completely free! Click here to join today! We highly recommend that you print a copy of our Guide for New Members. Enjoy!

Closed Thread
 
Thread Tools
rraymond's Avatar
Junior Member with 3 posts.
 
Join Date: Mar 2005
29-Mar-2005, 12:27 PM #1
Crystal Reports
I need only pull the last 5 digits of a phone number. The format is ###/###-####. I need to pull the last 5 digits in the following format #####. What function will give me the results I need?

Last edited by rraymond : 29-Mar-2005 04:03 PM. Reason: narrow search option
Rockn's Avatar
Computer Specs
Distinguished Member with 17,888 posts.
 
Join Date: Jul 2001
Location: Mexico of the North, MN
Experience: Disenfranchised American Male
29-Mar-2005, 12:54 PM #2
Which digits are you trying to get out of the phone number, the first four, second four or the middle four?
rraymond's Avatar
Junior Member with 3 posts.
 
Join Date: Mar 2005
29-Mar-2005, 04:05 PM #3
Quote:
Originally Posted by Rockn
Which digits are you trying to get out of the phone number, the first four, second four or the middle four?
I need to pull the last 5 digits in the following format #####. What function will give me the results I need?
coachdan32's Avatar
Computer Specs
Senior Member with 1,000 posts.
 
Join Date: Nov 2003
Location: Louisville, KY
30-Mar-2005, 09:08 AM #4
Take a look at the TRIM function.
Rockn's Avatar
Computer Specs
Distinguished Member with 17,888 posts.
 
Join Date: Jul 2001
Location: Mexico of the North, MN
Experience: Disenfranchised American Male
30-Mar-2005, 01:41 PM #5
I don't think trim will work as it only takes off trailing or leading spaces. CR is a different creature with it's own screwey syntax. I will look at CR when I get a chance.
Rockn's Avatar
Computer Specs
Distinguished Member with 17,888 posts.
 
Join Date: Jul 2001
Location: Mexico of the North, MN
Experience: Disenfranchised American Male
31-Mar-2005, 03:15 PM #6
Sorry it took so long to get back. Here is an easy way to do it. You need to create a formula like this:

Right(Replace({PhoneNumber},"-", ""),5)
rraymond's Avatar
Junior Member with 3 posts.
 
Join Date: Mar 2005
01-Apr-2005, 11:03 AM #7
Thanks everyone for your suggestions.

Unfornuately the formula Right(Replace({PhoneNumber},"-", ""),5) doesn't work because the command requires that the input field be numeric. I am receiving an error 'Formula result must be numeric'. Any other suggestions?
Rockn's Avatar
Computer Specs
Distinguished Member with 17,888 posts.
 
Join Date: Jul 2001
Location: Mexico of the North, MN
Experience: Disenfranchised American Male
01-Apr-2005, 12:37 PM #8
Do you have your phone number field set to text? If so put a ToText in front of everything above^^ ToText(Right(Replace({PhoneNumber},"-", ""),5))
Closed Thread

THIS THREAD HAS EXPIRED.
Are you having the same problem? We have volunteers ready to answer your question, but first you'll have to join for free. Need help getting started? Check out our Welcome Guide.


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
WELCOME TO TECH SUPPORT GUY! Are you looking for the solution to your computer problem? Join our site today to ask your question -- for free! Our site is run completely by volunteers who help people like you solve computer problems. See our Welcome Guide to get started.



Thread Tools


You Are Using:
Server ID
Advertisements do not imply our endorsement of that product or service.
All times are GMT -4. The time now is 05:15 PM.
Copyright © 1996 - 2008 TechGuy, Inc. All rights reserved.
Powered by vBulletin, Copyright © 2000 - 2008, Jelsoft Enterprises Ltd.
Search Engine Optimization by vBSEO 3.1.0
Powered by Cermak Technologies, Inc.