CiviCRM Community Forums (archive)

*

News:

Have a question about CiviCRM?
Get it answered quickly at the new
CiviCRM Stack Exchange Q+A site

This forum was archived on 25 November 2017. Learn more.
How to get involved.
What to do if you think you've found a bug.



  • CiviCRM Community Forums (archive) »
  • Old sections (read-only, deprecated) »
  • Support »
  • Using CiviCRM »
  • Using Import (Moderator: Yashodha Chaku) »
  • Postal code leading zero problem
Pages: [1]

Author Topic: Postal code leading zero problem  (Read 2178 times)

nnangeroni

  • I’m new here
  • *
  • Posts: 27
  • Karma: 2
  • CiviCRM version: 3.4.0
  • CMS version: Drupal 6.20
  • MySQL version: 5.5.x
  • PHP version: 5.3.x
Postal code leading zero problem
May 14, 2011, 04:39:33 pm
I'm trying to export records from one CiviCRM installation and import them into another.  The process works fine except the export function truncates leading zeroes in the postal code, the CSV file seems unable to retain them, and the import function does not restore them.  At what point in this export => import process can the leading zeroes be restored, or can the stored values be fixed?

Love the many CiviCRM improvements!

Donald Lobo

  • Administrator
  • I’m (like) Lobo ;)
  • *****
  • Posts: 15963
  • Karma: 470
    • CiviCRM site
  • CiviCRM version: 4.2+
  • CMS version: Drupal 7, Joomla 2.5+
  • MySQL version: 5.5.x
  • PHP version: 5.4.x
Re: Postal code leading zero problem
May 15, 2011, 08:55:53 am

r u sure its the export function? or r u loading the csv file into something like Excel and then saving it again?

if its the export function, can u save the csv and check the csv file via a text editor

lobo
A new CiviCRM Q&A resource needs YOUR help to get started. Visit our StackExchange proposed site, sign up and vote on 5 questions

nnangeroni

  • I’m new here
  • *
  • Posts: 27
  • Karma: 2
  • CiviCRM version: 3.4.0
  • CMS version: Drupal 6.20
  • MySQL version: 5.5.x
  • PHP version: 5.3.x
Re: Postal code leading zero problem
May 15, 2011, 01:26:02 pm
Thanks, Lobo.  The export is indeed complete with leading zeroes.  But the .csv files I imported into CiviCRM are not; Excel, when loading the .csv file, was truncating them.  Even correcting the format in Excel and saving the file again did not fix the problem.

The solution: convert the exported .csv file to an .xls format, then perform the format fix to zip code columns to restore the leading zeroes (format cells > special > zip code).  Then save as a .csv file, and this time the leading zeroes are intact.

I forgot to mention that I had also tried using the various formulas that people suggested to create new columns for zip code values, to no avail.

Thanks again for your help, hopefully this will help others.   ;D

Pages: [1]
  • CiviCRM Community Forums (archive) »
  • Old sections (read-only, deprecated) »
  • Support »
  • Using CiviCRM »
  • Using Import (Moderator: Yashodha Chaku) »
  • Postal code leading zero problem

This forum was archived on 2017-11-26.