Uploaded image for project: 'CiviCRM'
  1. CiviCRM
  2. CRM-14820

Cannot register event participant from admin menu

    Details

    • Type: Bug
    • Status: Done/Fixed
    • Priority: Minor
    • Resolution: Cannot Reproduce
    • Affects Version/s: 4.4.3
    • Fix Version/s: None
    • Component/s: CiviEvent

      Description

      We are on CiviCRM 4.4.3 / Wordpress

      We are trying to register event participants. We have both a user registration form (front end) and obviously a way to register participants from the Admin menu.

      When you register from the front end it works.. But, if you use the "Events -> Register Event participant" option from the backend - it does not.

      In one case (the working case), it is using the event_id to look up the constraint
      In the other case (backend - non-working case), it appears to be using the participant's id to look up a foreign key constraint against the events table and the IDs don't match

      If I go to the admin menu and try to register an event participant from there, i get this error:

      Array
      (
      [callback] => Array
      (

      => CRM_Core_Error
      [1] => handle
      )
      => -3
      [message] => DB Error: constraint violation
      [mode] => 16
      [debug_info] => INSERT INTO civicrm_value_conference_registration_12 ( participant_2_first_name_33,additional_participants_35,additional_conference_participan_41,entity_id ) VALUES ( '','','',712 ) ON DUPLICATE KEY UPDATE participant_2_first_name_33 = '',additional_participants_35 = '',additional_conference_participan_41 = '' [nativecode=1452 ** Cannot add or update a child row: a foreign key constraint fails (`fpwr_civi_433/civicrm_value_conference_registration_12`, CONSTRAINT `FK_civicrm_value_conference_registr_91ad01a1a86df0c7` FOREIGN KEY (`entity_id`) REFERENCES `civicrm_event` (`id`) ON DELET)]
      [type] => DB_Error
      [user_info] => INSERT INTO civicrm_value_conference_registration_12 ( participant_2_first_name_33,additional_participants_35,additional_conference_participan_41,entity_id ) VALUES ( '','','',712 ) ON DUPLICATE KEY UPDATE participant_2_first_name_33 = '',additional_participants_35 = '',additional_conference_participan_41 = '' [nativecode=1452 ** Cannot add or update a child row: a foreign key constraint fails (`fpwr_civi_433/civicrm_value_conference_registration_12`, CONSTRAINT `FK_civicrm_value_conference_registr_91ad01a1a86df0c7` FOREIGN KEY (`entity_id`) REFERENCES `civicrm_event` (`id`) ON DELET)]
      [to_string] => [db_error: message="DB Error: constraint violation" code=-3 mode=callback callback=CRM_Core_Error::handle prefix="" info="INSERT INTO civicrm_value_conference_registration_12 ( participant_2_first_name_33,additional_participants_35,additional_conference_participan_41,entity_id ) VALUES ( '','','',712 ) ON DUPLICATE KEY UPDATE participant_2_first_name_33 = '',additional_participants_35 = '',additional_conference_participan_41 = '' [nativecode=1452 ** Cannot add or update a child row: a foreign key constraint fails (`fpwr_civi_433/civicrm_value_conference_registration_12`, CONSTRAINT `FK_civicrm_value_conference_registr_91ad01a1a86df0c7` FOREIGN KEY (`entity_id`) REFERENCES `civicrm_event` (`id`) ON DELET)]"]
      )

      It appears that its using the participants entity_id, not the events entity_id - and the foreign key constraint / relationship is with the event table

      Workaround is to register people from the front end civievent forms - but it would be much easier and better if this was fixed.

        Attachments

          Activity

            People

            • Assignee:
              kurund Kurund Jalmi
              Reporter:
              jeffporter Jeff Porter
            • Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: