Solved

Remove spaces from postal code

Posted on 2014-03-03
3
353 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
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 22

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

Webinar: Aligning, Automating, Winning

Join Dan Russo, Senior Manager of Operations Intelligence, for an in-depth discussion on how Dealertrack, leading provider of integrated digital solutions for the automotive industry, transformed their DevOps processes to increase collaboration and move with greater velocity.

Question has a verified solution.

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

Using SQL Scripts we can save all the SQL queries as files that we use very frequently on our database later point of time. This is one of the feature present under SQL Workshop in Oracle Application Express.
A company’s centralized system that manages user data, security, and distributed resources is often a focus of criminal attention. Active Directory (AD) is no exception. In truth, it’s even more likely to be targeted due to the number of companies …
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…
Polish reports in Access so they look terrific. Take yourself to another level. Equations, Back Color, Alternate Back Color. Write easy VBA Code. Tighten space to use less pages. Launch report from a menu, considering criteria only when it is filled…

740 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