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

EXTRACT 4 CHARACTERS FROM A 6 CHAR FIELD

Status
Not open for further replies.

jobillborf

Programmer
Feb 13, 2001
61
US
HI, I HAVE A FIELD CALLED MODBY. It is 30 in length and a varchar field. The data has two letters then 4 numbers. For ex. WB1555. I would like to extract the 1555 from the data using a formula. Thank you for your help.
 
If the format of the field is static - in that it'll always be 2 letters, and 4 numbers, you could go:

Mid({Field},3,4)

3 being the position in the field you want to start extracting from, and 4 being how many characters you want extract.

Good luck with your report.

Naith
 
or you could try:

{field} [3 to 6] Ken Hamady, On-site Custom Crystal Reports Training & Consulting
Public classes and individual training.
Guide to using Crystal in VB
tek@kenhamady.com
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top