Laos 2009 © Tina Chen
New York City 2010 © Tina Chen
Rwanda 2007 © Tina Chen
Nepal 2008 © Tina Chen
Zambia 2005 © Tina Chen
The Galapagos 2008 © Tina Chen
Sweden 2010 © Tina Chen
Denmark 2010 © Tina Chen
France 2005 © Tina Chen
Nicaragua 2012 © Tina Chen
Costa Rica 2005 © Tina Chen
Germany 2010 © Tina Chen
The Bahamas 2010 © Tina Chen
Cambodia 2009 © Tina Chen
Austria 2009 © Tina Chen
India 2008 © Tina Chen
Tanzania 2007 © Tina Chen
Malaysia 2005 © Tina Chen
Namibia 2005 © Tina Chen
Botswana 2005 © Tina Chen
South Africa 2005 © Tina Chen
Egypt 2005 © Tina Chen
The United Kingdom 2005 © Tina Chen
Vietnam 2004 © Tina Chen
Kenya 2007 © Tina Chen
Canada 2003 © Tina Chen
Thailand 2004 © Tina Chen

How to: Solve Drupal/CiviCRM Error Messages

A collection of common Drupal and/or CiviCRM error messages and their solutions.

Drupal Error Message Solution
user warning: Duplicate entry '0' for key 1 query: INSERT INTO location ... In sequence table, increment location_lid (or the corresponding counter) to value greater than any other location_lid used in the system.
Cron failed - Attempting to re-run cron while it is already running
  1. flush all caches
  2. if unsuccessful, then via phpMyAdmin -> in variable table -> delete cron_semaphore.
  3. flush all chaches
  4. run cron!
CiviCRM Error Message Solution
user warning: Duplicate entry '0' for key 1 query: INSERT INTO location ...
  1. In sequence table, increment location_lid (or the corresponding counter) to value greater than any other location_lid used in the system.
  2. In location and location_instance tables, set the lid field's extra property to auto_increment.
error: Fatal error: Maximum execution time of 30 seconds exceeded in \includes\file.inc
  • In php.ini, increase max_execution_time to 120
The user account used by your web-server needs to be granted write access to the following directory in order to configure the CiviCRM settings file (during CiviCRM installation)
  1. Start > Run > cmd
  2. Navigate to /sites folder and type: attrib -r default /s /d
Fatal error: Class 'CRM_Import_Field' not found in /civicrm/CRM/Import/Parser.php on line 732 (during CiviCRM contact import)
  1. Create a new empty db for CRM
  2. Delete old civicrm.settings.php
  3. Reinstall CiviCRM /civicrm/install/index.php using old Drupal db using the new CRM db
  4. Open new civicrm.settings.php and change new CRM db name to old CRM db name
HP Fatal error: Uncaught exception 'Exception' with message 'Please make sure the IDS/tmp folder is writable' in /civicrm/packages/IDS/Monitor.php
  • Change permission of /sites/default/files/civicrm/upload/ folder to writable (777). You can use any FTP software, upload the file, and change it's permission.
user warning: BLOB/TEXT column 'status_codes' can't have a default value query: CREATE TABLE civicrm_member_roles_rules ( `rule_id` INT unsigned NOT NULL auto_increment, `rid` INT unsigned NOT NULL, `type_id` INT unsigned NOT NULL, `status_codes` TEXT NOT NULL DEFAULT '', PRIMARY KEY (rule_id) ) in \includes\database.inc
  • In civicrm_member_roles.install, delete line 41: 'default' => '',
user warning: Incorrect integer value: '' for column 'rule_id' at row 1 query: INSERT INTO civicrm_member_roles_rules (rule_id, rid, type_id, status_codes) VALUES('', 3, 1, '...'') in /civicrm_member_roles.module
  • In civicrm_member_roles.module, replace ln 357-358:
    $add_rule = db_query('INSERT INTO {civicrm_member_roles_rules} (rule_id, rid, type_id, status_codes) VALUES(\'\', %d, %d, \'%s\')',

    with:
    $add_rule = db_query('INSERT INTO {civicrm_member_roles_rules} (rid, type_id, status_codes)< VALUES(%d, %d, \'%s\')',

Call to undefined function curl_init() in CRM\Core\Payment\PayPalImpl.php (when submitting new membership)
  • in php.ini, remove ; before extension=php_curl.dll and restart server
Sorry. A non-recoverable error has occurred. DB Error: constraint violation. Database Error Code: Cannot add or update a child row: a foreign key constraint fails (`crm`.`civicrm_log`, CONSTRAINT `FK_civicrm_log_modified_id` FOREIGN KEY (`modified_id`) REFERENCES `civicrm_contact` (`id`) ON DELETE CASCADE), 1452
  1. Make sure paths are updated: /civicrm/admin/setting/
    updateConfigBackend?reset=1
  2. Make sure direcotires are upddated: /civicrm/admin/setting/path
user warning: Duplicate entry '0' for key 1 query: INSERT INTO location ... In sequence table, increment location_lid (or the corresponding counter) to value greater than any other location_lid used in the system.

Comments

NOTE: Your email is safe and will never be misused.

In my twenty plus years of teaching, I would place Tina in the top 1%. She is truly an outstanding individual. When she undertakes a project, she shows a passion and drive that guarantees success for the venture.

Gary Johnson, Chair of Science Department, Marianopolis College

About the Director

Tina Chen, International Web StrategistI believe in the greatness in people. When I chose Doctors Without Borders over Chase Bank and UNICEF over The NY Times, I believed in people's potential to enhance the quality of life of others, thousands of others. This is why I do what I do. I use International Web Strategy™ to shine what YOU do.