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 CiviEvent (Moderator: Yashodha Chaku) »
  • Database error regarding deleted field when trying to register user for an event
Pages: [1]

Author Topic: Database error regarding deleted field when trying to register user for an event  (Read 689 times)

leupi

  • I post frequently
  • ***
  • Posts: 192
  • Karma: 2
Database error regarding deleted field when trying to register user for an event
December 17, 2013, 12:10:45 pm
I created a custom field and added it to a profile of which I was using for an event registration. I've since deleted the custom field but whenever I try to register a user via CiviCRM's 'Register event participant' menu item I get the following error:
Quote
Sorry but we are not able to provide this at the moment.
DB Error: no such field
Return to home page.
I looked up the error logs and found this:
Code: [Select]
Dec 17 15:03:53  [info] $backTrace = #0 C:\apache2\htdocs\drupal\sites\all\modules\civicrm\CRM\Core\Error.php(196): CRM_Core_Error::backtrace("backTrace", TRUE)
#1 [internal function](): CRM_Core_Error::handle(Object(DB_Error))
#2 C:\apache2\htdocs\drupal\sites\all\modules\civicrm\packages\PEAR.php(931): call_user_func((Array:2), Object(DB_Error))
#3 C:\apache2\htdocs\drupal\sites\all\modules\civicrm\packages\DB.php(969): PEAR_Error->PEAR_Error("DB Error: no such field", -19, 16, (Array:2), "INSERT INTO civicrm_value_innm_training_19  ( what_is_your_primary_goal_in_at...")
#4 C:\apache2\htdocs\drupal\sites\all\modules\civicrm\packages\PEAR.php(564): DB_Error->DB_Error(-19, 16, (Array:2), "INSERT INTO civicrm_value_innm_training_19  ( what_is_your_primary_goal_in_at...")
#5 C:\apache2\htdocs\drupal\sites\all\modules\civicrm\packages\DB\common.php(1905): PEAR->raiseError(NULL, -19, NULL, NULL, "INSERT INTO civicrm_value_innm_training_19  ( what_is_your_primary_goal_in_at...", "DB_Error", TRUE)
#6 C:\apache2\htdocs\drupal\sites\all\modules\civicrm\packages\DB\mysql.php(898): DB_common->raiseError(-19, NULL, NULL, NULL, "1054 ** Unknown column 'i_will_be_staying_at_the_followi_175' in 'field list'")
#7 C:\apache2\htdocs\drupal\sites\all\modules\civicrm\packages\DB\mysql.php(327): DB_mysql->mysqlRaiseError()
#8 C:\apache2\htdocs\drupal\sites\all\modules\civicrm\packages\DB\common.php(1216): DB_mysql->simpleQuery("INSERT INTO civicrm_value_innm_training_19  ( what_is_your_primary_goal_in_at...")
#9 C:\apache2\htdocs\drupal\sites\all\modules\civicrm\packages\DB\DataObject.php(2421): DB_common->query("INSERT INTO civicrm_value_innm_training_19  ( what_is_your_primary_goal_in_at...")
#10 C:\apache2\htdocs\drupal\sites\all\modules\civicrm\packages\DB\DataObject.php(1613): DB_DataObject->_query("INSERT INTO civicrm_value_innm_training_19  ( what_is_your_primary_goal_in_at...")
#11 C:\apache2\htdocs\drupal\sites\all\modules\civicrm\CRM\Core\DAO.php(155): DB_DataObject->query("INSERT INTO civicrm_value_innm_training_19  ( what_is_your_primary_goal_in_at...")
#12 C:\apache2\htdocs\drupal\sites\all\modules\civicrm\CRM\Core\DAO.php(917): CRM_Core_DAO->query("INSERT INTO civicrm_value_innm_training_19  ( what_is_your_primary_goal_in_at...", TRUE)
#13 C:\apache2\htdocs\drupal\sites\all\modules\civicrm\CRM\Core\BAO\CustomValueTable.php(236): CRM_Core_DAO::executeQuery("INSERT INTO civicrm_value_innm_training_19  ( what_is_your_primary_goal_in_at...", (Array:24))
#14 C:\apache2\htdocs\drupal\sites\all\modules\civicrm\CRM\Core\BAO\CustomValueTable.php(338): CRM_Core_BAO_CustomValueTable::create((Array:3))
#15 C:\apache2\htdocs\drupal\sites\all\modules\civicrm\CRM\Event\BAO\Participant.php(224): CRM_Core_BAO_CustomValueTable::store((Array:35), "civicrm_participant", 840)
#16 C:\apache2\htdocs\drupal\sites\all\modules\civicrm\CRM\Event\Form\Participant.php(1370): CRM_Event_BAO_Participant::create((Array:63))
#17 C:\apache2\htdocs\drupal\sites\all\modules\civicrm\CRM\Core\Form.php(246): CRM_Event_Form_Participant->postProcess()
#18 C:\apache2\htdocs\drupal\sites\all\modules\civicrm\CRM\Core\QuickForm\Action\Upload.php(151): CRM_Core_Form->mainProcess()
#19 C:\apache2\htdocs\drupal\sites\all\modules\civicrm\CRM\Core\QuickForm\Action\Upload.php(128): CRM_Core_QuickForm_Action_Upload->realPerform(Object(CRM_Event_Form_Participant), "upload")
#20 C:\apache2\htdocs\drupal\sites\all\modules\civicrm\packages\HTML\QuickForm\Controller.php(203): CRM_Core_QuickForm_Action_Upload->perform(Object(CRM_Event_Form_Participant), "upload")
#21 C:\apache2\htdocs\drupal\sites\all\modules\civicrm\packages\HTML\QuickForm\Page.php(103): HTML_QuickForm_Controller->handle(Object(CRM_Event_Form_Participant), "upload")
#22 C:\apache2\htdocs\drupal\sites\all\modules\civicrm\CRM\Core\Controller.php(316): HTML_QuickForm_Page->handle("upload")
#23 C:\apache2\htdocs\drupal\sites\all\modules\civicrm\CRM\Event\Page\Tab.php(115): CRM_Core_Controller->run()
#24 C:\apache2\htdocs\drupal\sites\all\modules\civicrm\CRM\Event\Page\Tab.php(175): CRM_Event_Page_Tab->edit()
#25 C:\apache2\htdocs\drupal\sites\all\modules\civicrm\CRM\Core\Invoke.php(292): CRM_Event_Page_Tab->run((Array:3), NULL)
#26 C:\apache2\htdocs\drupal\sites\all\modules\civicrm\CRM\Core\Invoke.php(70): CRM_Core_Invoke::runItem((Array:14))
#27 C:\apache2\htdocs\drupal\sites\all\modules\civicrm\CRM\Core\Invoke.php(52): CRM_Core_Invoke::_invoke((Array:3))
#28 C:\apache2\htdocs\drupal\sites\all\modules\civicrm\drupal\civicrm.module(354): CRM_Core_Invoke::invoke((Array:3))
#29 [internal function](): civicrm_invoke("participant", "add")
#30 C:\apache2\htdocs\drupal\includes\menu.inc(350): call_user_func_array("civicrm_invoke", (Array:2))
#31 C:\apache2\htdocs\drupal\index.php(17): menu_execute_active_handler()
#32 {main}
The 'what_is_your_primary_goal_in_at...' is the field that I deleted a while back. Any thoughts on what I might be able to do to allow event registration via CiviCRM's menu option? Regular event registration seems to be functional.

Thanks!

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: Database error regarding deleted field when trying to register user for an event
December 17, 2013, 02:08:10 pm

a. how did u delete the custom field

b. If via the UI, did u get an error when deleting it?

seems like there is some inconsistency in the db about that custom field, so i suspect some work will be needed directly on the db to clean things up. Might want to delete the custom field record in the db if needed and then rebuild the civicrm menu (which clears the caches etc)

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

leupi

  • I post frequently
  • ***
  • Posts: 192
  • Karma: 2
Re: Database error regarding deleted field when trying to register user for an event
December 18, 2013, 08:00:36 am
Thanks for the reply.

I'm not sure if I got an error message when originally deleting the field via the GUI but I'm certainly getting them now. When I delete a field I get the following message:
Quote
Sorry but we are not able to provide this at the moment.
DB Error: a515ac9c2796ca0e23adbe92c68fc9fc
Return to home page.
I notice that the field has been removed from the database, at least looking at it through phpmyadmin I see that the field is no longer there. The field does, however, continue to show up in the custom fields within CiviCRM. If I try to delete it again I get the following:
Quote
Sorry but we are not able to provide this at the moment.
DB Error: not found
Return to home page.
This is then throwing errors when trying to register someone for an event on the backend as that registration seems to be still looking for those fields that have been removed. I have rebuilt the menu but it makes no difference.

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: Database error regarding deleted field when trying to register user for an event
December 18, 2013, 08:53:32 am

can u check civicrm_custom_field and see if that field exists there, if so might want to delete that row

if that does not fix it, i suspect u'll need to get someone to take a closer look at the DB and figure out what is happening and why

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

Pages: [1]
  • CiviCRM Community Forums (archive) »
  • Old sections (read-only, deprecated) »
  • Support »
  • Using CiviCRM »
  • Using CiviEvent (Moderator: Yashodha Chaku) »
  • Database error regarding deleted field when trying to register user for an event

This forum was archived on 2017-11-26.