Improve company productivity with a Business Account.Sign Up

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 380
  • Last Modified:

Remove spaces from postal code

How can I remove the spaces from the postal code as per the following?

These are Canadian post codes
A2B 4Y3
A2B4Y3

In the database a user can add the data both ways but on the Crystal report I want to show with no spaces.

The field name is: BVPOSTALCODE and it is a pervasive database
0
Gerhardpet
Asked:
Gerhardpet
2 Solutions
 
Bill BachPresidentCommented:
PSQL supports the REPLACE() function, which is used like this:
    SELECT REPLACE(BVPOSTALCODE,' ','') FROM tablename
0
 
Ido MilletProfessor of MIS at Penn State Erie and Owner, Millet SoftwareCommented:
Or if you wish to use a Crystal formula to do the cleanup,
Replace({BVPOSTALCODE}, " ", "")
0
 
GerhardpetAuthor Commented:
I needed the Crystal formula and both work.
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

Join & Write a Comment

Featured Post

Free Tool: Path Explorer

An intuitive utility to help find the CSS path to UI elements on a webpage. These paths are used frequently in a variety of front-end development and QA automation tasks.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

Tackle projects and never again get stuck behind a technical roadblock.
Join Now