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) »
  • No validation for data types or data mismatches in customised data
Pages: [1]

Author Topic: No validation for data types or data mismatches in customised data  (Read 968 times)

SweetTooth

  • I post occasionally
  • **
  • Posts: 70
  • Karma: 1
  • CiviCRM version: 4.1
  • CMS version: Drupal 6.20
  • MySQL version: 5.1.54
  • PHP version: 5.2.17
No validation for data types or data mismatches in customised data
February 24, 2011, 04:00:58 pm

Hi,

I spent a lot of time today finding out the hard way, that there is no validation when trying to import non-integer data into a CiviCRM custom data type that is declared in civicrm as an integer. Rather than tell me that there is data that can't be imported, it would simply bomb out with the web browser trying to open "Contact" as an application with screen output being downloaded as a text file to the web browser.

Of course my data should have been correct, but it takes just one record out of the typical 10,000 that I upload in one go to be wrong, for this to happen.

Now that I know what to look for, great, but it really did take a good few hours of elimanation work before I found the exact problem.

It would be really nice if as a feature, there was some kind of extra data validation done by CiviCRM when it imports, with some user friendly error messages, as it would save a lot of people a lot of time!

Keep up the good work!


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: No validation for data types or data mismatches in customised data
February 24, 2011, 05:21:14 pm

can u elaborate a bit on what u mean by bombing out

can you reproduce this on our demo server with a small sample csv file. In the worst case, even an ugly error message is better than "bombing out"

thanx

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

SweetTooth

  • I post occasionally
  • **
  • Posts: 70
  • Karma: 1
  • CiviCRM version: 4.1
  • CMS version: Drupal 6.20
  • MySQL version: 5.1.54
  • PHP version: 5.2.17
Re: No validation for data types or data mismatches in customised data
February 24, 2011, 07:02:37 pm

Hi Lobo,

Just reproduced it on the demo 3.3 server.

Created a custom field called IntegerCustomField, with data type Integer.

Then uploaded a simple test file with

"King", "George", "10 01"

mapping "King" to first name, "George" to last name and "10 01" to IntegerCustomField

And it bombs with a load of html code and all that, etc.


Pages: [1]
  • CiviCRM Community Forums (archive) »
  • Old sections (read-only, deprecated) »
  • Support »
  • Using CiviCRM »
  • Using Import (Moderator: Yashodha Chaku) »
  • No validation for data types or data mismatches in customised data

This forum was archived on 2017-11-26.