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) »
  • Discussion (deprecated) »
  • Alpha and Beta Release Testing »
  • 2.1 Release Testing »
  • mysql error upgrading 2.0 to 2.1 (joomla to standalone)
Pages: [1]

Author Topic: mysql error upgrading 2.0 to 2.1 (joomla to standalone)  (Read 2956 times)

drewaharris

  • Guest
mysql error upgrading 2.0 to 2.1 (joomla to standalone)
September 05, 2008, 11:06:33 am
Hi,

I'm a bit of a neophyte running 2.0 under Joomla 1.5 (legacy). Now, I'm trying to upgrade to 2.1 standalone. During the install, I enter the name of the current database and the install proceeds until this error:
Code: [Select]
DB Error: constraint violation

Database Error Code: Cannot add or update a child row: a foreign key constraint fails (`XXXX_civicrm/civicrm_acl_cache`, CONSTRAINT `FK_civicrm_acl_cache_contact_id` FOREIGN KEY (`contact_id`) REFERENCES `civicrm_contact` (`id`) ON DELETE CASCADE), 1452

Error Details:

Array
(
    [callback] => Array
        (
            [0] => CRM_Core_Error
            [1] => handle
        )

    [code] => -3
    [message] => DB Error: constraint violation
    [mode] => 16
    [debug_info] => INSERT INTO civicrm_acl_cache (contact_id , acl_id ) VALUES ( 1 ,  2 )  [nativecode=1452 ** Cannot add or update a child row: a foreign key constraint fails (`XXXX_civicrm/civicrm_acl_cache`, CONSTRAINT `FK_civicrm_acl_cache_contact_id` FOREIGN KEY (`contact_id`) REFERENCES `civicrm_contact` (`id`) ON DELETE CASCADE)]
    [type] => DB_Error
    [user_info] => INSERT INTO civicrm_acl_cache (contact_id , acl_id ) VALUES ( 1 ,  2 )  [nativecode=1452 ** Cannot add or update a child row: a foreign key constraint fails (`XXXX_civicrm/civicrm_acl_cache`, CONSTRAINT `FK_civicrm_acl_cache_contact_id` FOREIGN KEY (`contact_id`) REFERENCES `civicrm_contact` (`id`) ON DELETE CASCADE)]
    [to_string] => [db_error: message="DB Error: constraint violation" code=-3 mode=callback callback=CRM_Core_Error::handle prefix="" info="INSERT INTO civicrm_acl_cache (contact_id , acl_id ) VALUES ( 1 ,  2 )  [nativecode=1452 ** Cannot add or update a child row: a foreign key constraint fails (`XXXX_civicrm/civicrm_acl_cache`, CONSTRAINT `FK_civicrm_acl_cache_contact_id` FOREIGN KEY (`contact_id`) REFERENCES `civicrm_contact` (`id`) ON DELETE CASCADE)]"]
)

My goal is to run standalone. I couldn't get the 2.0 standalone version to work because the install script requires mysql admin access, which I don't have at Bluehost. I'm running it under Joomla 1.5 (legacy), but this is strictly an in-house setup that doesn't need it.

Thanks for your help.

drew[/code]

Kurund Jalmi

  • Administrator
  • I’m (like) Lobo ;)
  • *****
  • Posts: 4169
  • Karma: 128
    • CiviCRM
  • CiviCRM version: 4.x, future
  • CMS version: Drupal 7, Joomla 3.x
  • MySQL version: 5.5.x
  • PHP version: 5.4.x
Re: mysql error upgrading 2.0 to 2.1 (joomla to standalone)
September 05, 2008, 12:38:01 pm
Drew:

First of all CiviCRM officially supports v2.0 on  Joomla 1.0.13. Are you trying to upgrade CiviCRM -joomla install to civicrm standalone version ?
IMO it won't work correctly.

Kurund

Found this reply helpful? Support CiviCRM

drewaharris

  • Guest
Re: mysql error upgrading 2.0 to 2.1 (joomla to standalone)
September 05, 2008, 01:51:07 pm
Kurund:

Yes. I want to switch to Standalone. I don't need the Joomla functionality in this setup, but I couldn't get Civicrm to install without it.

I assumed that sql structure was the same in all three versions. I guess it's not. Right?

Is there any way of moving my data from one setup to another?

Thanks for your help.

Drew

Kurund Jalmi

  • Administrator
  • I’m (like) Lobo ;)
  • *****
  • Posts: 4169
  • Karma: 128
    • CiviCRM
  • CiviCRM version: 4.x, future
  • CMS version: Drupal 7, Joomla 3.x
  • MySQL version: 5.5.x
  • PHP version: 5.4.x
Re: mysql error upgrading 2.0 to 2.1 (joomla to standalone)
September 05, 2008, 02:11:19 pm
Drew:

Quote
I assumed that sql structure was the same in all three versions. I guess it's not. Right?
Yes.

I would suggest following steps.

1. Take database dump of CivCRM v2.0. Is CiviCRM part of joomla database or separate database for civicrm?

2. Get CiviCRM Standalone version running with above CiviCRM v2.0 dump.

3. Then try to upgrade CiviCRM v2.0 - Stanalone to CiviCRM v2.1 - Standalone.

I don't think its a good idea to upgrade CiviCRM v2.0 + Joomla to CiviCRM v2.1 - Standalone.

HTH

Kurund


Found this reply helpful? Support CiviCRM

drewaharris

  • Guest
Re: mysql error upgrading 2.0 to 2.1 (joomla to standalone)
September 05, 2008, 02:28:46 pm
Unfortunately, I can't install 2.0 Standalone. The installer requires root access to Mysql, which Bluehost doesn't give me. It's a known problem: http://forum.civicrm.org/index.php/topic,3612.0.html

Do you know a workaround to get 2.0 standalone up and running?

Drew

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: mysql error upgrading 2.0 to 2.1 (joomla to standalone)
September 05, 2008, 04:01:48 pm

another possible option is to:

1. upgrade your joomla to 2.1

2. then install civicrm standalone 2.1 (which has been worked on quite a bit)

and then transfer the appropriate tables as needed. I suspect you will need to do some db merging (with the open id tables related to standalone)

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) »
  • Discussion (deprecated) »
  • Alpha and Beta Release Testing »
  • 2.1 Release Testing »
  • mysql error upgrading 2.0 to 2.1 (joomla to standalone)

This forum was archived on 2017-11-26.