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 »
  • Installing CiviCRM »
  • Drupal Installations (Moderator: Piotr Szotkowski) »
  • "contribution type not valid"
Pages: [1]

Author Topic: "contribution type not valid"  (Read 1271 times)

TheoRichel

  • I post frequently
  • ***
  • Posts: 122
  • Karma: 0
  • CiviCRM version: 4.2.1
  • CMS version: Drupal 6.24
  • MySQL version: 5.9
  • PHP version: 5.3.16
"contribution type not valid"
May 02, 2011, 07:09:54 am
I am trying to import contributions from Drupal into Civicrm but it doesnt import anything because of"Contribution type not valid".

In my Drupal Database I have no specific field for Contribution type, I try to import dates and amounts and have a field of which I can see it has a value 0 (zero, it is not empty). I have used the zero as well in the special code that one can set when editing Contribution types (the third field).

Another strange thing is that it doesnt complain about his invalid typ in preview, it just says so after importing.

Fyi: In the Drupal profiles we have created date fields and money fields to register donations. Now I want these fields imported to the contributions pages of CivicRM. The contacts themselves are already there.
« Last Edit: May 02, 2011, 08:40:06 am by TheoRichel »

Hershel

  • Forum Godess / God
  • I’m (like) Lobo ;)
  • *****
  • Posts: 4640
  • Karma: 176
    • CiviHosting
  • CiviCRM version: Latest
  • CMS version: Mostly WordPress and Drupal
Re: "contribution type not valid"
May 02, 2011, 07:11:37 am
Sounds like you need to set your contribution type to match a valid one in CiviCRM. Values start from 1.
CiviHosting and CiviOnline -- The CiviCRM hosting experts, since 2007

See here for the official: What to do if you think you've found a bug.

TheoRichel

  • I post frequently
  • ***
  • Posts: 122
  • Karma: 0
  • CiviCRM version: 4.2.1
  • CMS version: Drupal 6.24
  • MySQL version: 5.9
  • PHP version: 5.3.16
Re: "contribution type not valid"
May 02, 2011, 08:22:55 am
Thanks, but when I use another field in Drupal that carries the value '1' and tell Civicrm that that is the identifier of the Contributiontype, exactly the same happens: Invalid contribution type.

But I must say that the information on this is scarce or I havent looked right. Where can I find the requirements for the Contributiontype field? Am I right that the 'Administrative Code' field is where I should give this number in to connect to Drupal

Hershel

  • Forum Godess / God
  • I’m (like) Lobo ;)
  • *****
  • Posts: 4640
  • Karma: 176
    • CiviHosting
  • CiviCRM version: Latest
  • CMS version: Mostly WordPress and Drupal
Re: "contribution type not valid"
May 02, 2011, 08:24:19 am
I don't actually know precisely what you are doing. What method are you using to "to import contributions from Drupal into Civicrm" ?
CiviHosting and CiviOnline -- The CiviCRM hosting experts, since 2007

See here for the official: What to do if you think you've found a bug.

TheoRichel

  • I post frequently
  • ***
  • Posts: 122
  • Karma: 0
  • CiviCRM version: 4.2.1
  • CMS version: Drupal 6.24
  • MySQL version: 5.9
  • PHP version: 5.3.16
Re: "contribution type not valid"
May 02, 2011, 08:38:16 am
I am trying to import contributions fromDrupal into Civicrm. I assign a contactfield to connect to the contact already in Civicrm, I assign a date field and a total amount field, all very straightforward. But then it also asks me for a Contribution type. Now in Drupal I have no such thing as a Contribution type, and meanwhile I have found out that the accounting code I used was for exporting purposes, so that explains somtething, but still leaves the question: hoe do I import these payments into CivicRM. What is my Contributiontype.

I have made contributiontypes in Civicrm, but only because the importer asks for them, but apparently I cannot connect the two.

Denver Dave

  • Ask me questions
  • ****
  • Posts: 471
  • Karma: 9
Re: "contribution type not valid"
May 02, 2011, 01:28:47 pm
Just a thought - create the contribution type, manually create one, export it and then see if the record and values is different that what you think.

If we are unable to upgrade from 1.9, we may  be in the same issue as well as matching new contact id numbers.

Good luck - please report back.

TheoRichel

  • I post frequently
  • ***
  • Posts: 122
  • Karma: 0
  • CiviCRM version: 4.2.1
  • CMS version: Drupal 6.24
  • MySQL version: 5.9
  • PHP version: 5.3.16
Re: "contribution type not valid"
May 03, 2011, 02:17:29 am
That was a good suggestion, thanks. I found out that Civiocrm just looks for the exact name of the contribution type in the imported records. I had a contribution type named Donations, but in the csv I exported from Drupal I only had a field available with the value  '1'. So I renamed Donations in Civicrm to '1' and there I went.

There are still some glitches however but I'll use another thread for that.

Pages: [1]
  • CiviCRM Community Forums (archive) »
  • Old sections (read-only, deprecated) »
  • Support »
  • Installing CiviCRM »
  • Drupal Installations (Moderator: Piotr Szotkowski) »
  • "contribution type not valid"

This forum was archived on 2017-11-26.