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 Core CiviCRM Functions (Moderator: Yashodha Chaku) »
  • Import activities - format dd/mm/yyyy not working
Pages: [1]

Author Topic: Import activities - format dd/mm/yyyy not working  (Read 591 times)

clarkac

  • Administrator
  • Ask me questions
  • *****
  • Posts: 399
  • Karma: 11
  • CiviCRM version: 4.4.11 & 4.5.5
  • CMS version: Drupal 7
  • MySQL version: 5.1.61-cll
  • PHP version: 5.3.27
Import activities - format dd/mm/yyyy not working
April 24, 2013, 05:22:59 am
If you select the date format dd/mm/yyyy when importing activities in 4.3.1 (don't know about other releases) then Civi ignores that and assumes yyyy/mm/dd.  So some records will be rejected and some corrupted.   Easy workaround is to reformat your input dates to yyyy/mm/dd.  I've raised this issue http://issues.civicrm.org/jira/browse/CRM-12417
Andy Clark

kennedy

  • I post occasionally
  • **
  • Posts: 119
  • Karma: 5
  • CiviCRM version: 4.5.5
  • CMS version: Drupal
  • PHP version: 5.3.10
Re: Import activities - format dd/mm/yyyy OR mm/dd/yyyy not working
August 19, 2014, 07:30:05 am
Hi,
I have been trying to import activities but with no luck, Invalid value for field(s) : Activity date
I have attached two files, the initial file and the error report file. The activities marked in red are the only activities not imported, it seems if day is >12, it throws an error. Any ideas? I have been having the same error messages on my site and on the demo site as well.
Here is the link to the successful activity import on the demo site http://drupal.demo.civicrm.org/civicrm/activity/search?_qf_Search_display=true&qfKey=39fbcd123ef3008cdde88452c7ee224d_9621

Any hint will be of great help.
« Last Edit: August 19, 2014, 07:33:53 am by kennedy »

clarkac

  • Administrator
  • Ask me questions
  • *****
  • Posts: 399
  • Karma: 11
  • CiviCRM version: 4.4.11 & 4.5.5
  • CMS version: Drupal 7
  • MySQL version: 5.1.61-cll
  • PHP version: 5.3.27
Re: Import activities - format dd/mm/yyyy not working
August 19, 2014, 01:56:50 pm
...then I would assume you selected dd/mm/yyyy instead of mm/dd/yyyy which is why you get the error... you don't say what you selected.
Andy Clark

joanne

  • Administrator
  • Ask me questions
  • *****
  • Posts: 852
  • Karma: 83
  • CiviCRM version: 4.4.16
  • CMS version: Drupal 7
Re: Import activities - format dd/mm/yyyy not working
August 19, 2014, 03:58:50 pm
I seem to remember that there was a bug related to this that was fixed in later versions of 4.4.X series.  An upgrade to 4.4.6 may fix your problem. 

You should upgrade anyway as 4.4.6 included security fixes.

kennedy

  • I post occasionally
  • **
  • Posts: 119
  • Karma: 5
  • CiviCRM version: 4.5.5
  • CMS version: Drupal
  • PHP version: 5.3.10
Re: Import activities - format dd/mm/yyyy not working
August 19, 2014, 08:54:19 pm
Hi Joanne and Clark,
thank you for you time, it seems  mm/dd/yyyy works, have just tested it in an old install running 4.4.3. Will also run it on a new install later today and report back.

Setting the date format in administer>Localization>Date formats is not enough, the same date format has to be also selected on the first screen (Contacts > Import Activities) during import.

Many thanks
« Last Edit: August 19, 2014, 09:23:15 pm by kennedy »

kennedy

  • I post occasionally
  • **
  • Posts: 119
  • Karma: 5
  • CiviCRM version: 4.5.5
  • CMS version: Drupal
  • PHP version: 5.3.10
Re: Import activities - format dd/mm/yyyy not working
August 19, 2014, 10:28:10 pm
also works with format mm/dd/yyyy on 4.4.6 but setting date format in administer>Localization>Date formats is not enough, the same date format has to be also selected on the first screen (Contacts > Import Activities) during import.

Thanks

clarkac

  • Administrator
  • Ask me questions
  • *****
  • Posts: 399
  • Karma: 11
  • CiviCRM version: 4.4.11 & 4.5.5
  • CMS version: Drupal 7
  • MySQL version: 5.1.61-cll
  • PHP version: 5.3.27
Re: Import activities - format dd/mm/yyyy not working
August 20, 2014, 01:04:53 am
Yes, that's true you have to specify the date format on all the import screens.  This makes some sense as the file you are importing may have the date  formatted differently from your usual format.
Andy Clark

Pages: [1]
  • CiviCRM Community Forums (archive) »
  • Old sections (read-only, deprecated) »
  • Support »
  • Using CiviCRM »
  • Using Core CiviCRM Functions (Moderator: Yashodha Chaku) »
  • Import activities - format dd/mm/yyyy not working

This forum was archived on 2017-11-26.