Solved

Remove spaces from postal code

Posted on 2014-03-03
3
359 Views
Last Modified: 2014-03-03
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
Comment
Question by:Gerhardpet
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
3 Comments
 
LVL 28

Assisted Solution

by:Bill Bach
Bill Bach earned 250 total points
ID: 39901461
PSQL supports the REPLACE() function, which is used like this:
    SELECT REPLACE(BVPOSTALCODE,' ','') FROM tablename
0
 
LVL 23

Accepted Solution

by:
Ido Millet earned 250 total points
ID: 39901535
Or if you wish to use a Crystal formula to do the cleanup,
Replace({BVPOSTALCODE}, " ", "")
0
 
LVL 1

Author Closing Comment

by:Gerhardpet
ID: 39901580
I needed the Crystal formula and both work.
0

Featured Post

Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Never store passwords in plain text or just their hash: it seems a no-brainier, but there are still plenty of people doing that. I present the why and how on this subject, offering my own real life solution that you can implement right away, bringin…
Microsoft Access is a place to store data within tables and represent this stored data using multiple database objects such as in form of macros, forms, reports, etc. After a MS Access database is created there is need to improve the performance and…
Video by: Steve
Using examples as well as descriptions, step through each of the common simple join types, explaining differences in syntax, differences in expected outputs and showing how the queries run along with the actual outputs based upon a simple set of dem…
This is a high-level webinar that covers the history of enterprise open source database use. It addresses both the advantages companies see in using open source database technologies, as well as the fears and reservations they might have. In this…

734 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question