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 »
  • Upgrading CiviCRM (Moderator: Deepak Srivastava) »
  • Database upgrade step fails 2.0.2 ---> 2.1.0 Joomla 1.5.9
Pages: [1]

Author Topic: Database upgrade step fails 2.0.2 ---> 2.1.0 Joomla 1.5.9  (Read 1328 times)

mrnoah

  • Guest
Database upgrade step fails 2.0.2 ---> 2.1.0 Joomla 1.5.9
March 18, 2009, 04:40:13 pm
So I upgraded from Joomla 1.5.2 to Joomla 1.5.9... that went well, and it didn't break my civicrm install.

I had been running Civicrm 2.0.2 (well, on my real site, I still am...)
I'm excited about upgrading to 2.2... so I started following the directions to upgrade to 2.1, and the installation seems to work fine... only the database does not upgrade (this step fails).  I've tried refreshing this and that, and running the upgrade script again. The database doesn't seem to want to upgrade. Is there, perhaps some simple thing I can do to make it easier for the database upgrade script to succeed ?

Rebuilding my database doesn't sound simple.... can you guys shed some light on this ?


Code: [Select]
Warning: Smarty error: unable to read resource: "CRM/error.tpl" in ***joomla root***/administrator/components/com_civicrm/civicrm/packages/Smarty/Smarty.class.php on line 1092

***
Sorry. A non-recoverable error has occurred.

Database consistency check failed. FK constraint names not in the required format. Please rebuild your 2.0 database to ensure schema integrity.

Return to home pag


Code: [Select]
backTrace

**joomla root**/administrator/components/com_civicrm/civicrm/CRM/Core/Error.php, backtrace, 138
, handle,
**joomla root**/administrator/components/com_civicrm/civicrm/packages/PEAR.php, call_user_func, 912
**joomla root**/administrator/components/com_civicrm/civicrm/packages/DB.php, PEAR_Error, 966
**joomla root**/administrator/components/com_civicrm/civicrm/packages/PEAR.php, DB_Error, 574
**joomla root**/administrator/components/com_civicrm/civicrm/packages/DB/common.php, raiseError, 1903
**joomla root**/administrator/components/com_civicrm/civicrm/packages/DB/mysql.php, raiseError, 898
**joomla root**/administrator/components/com_civicrm/civicrm/packages/DB/mysql.php, mysqlRaiseError, 327
**joomla root**/administrator/components/com_civicrm/civicrm/packages/DB/common.php, simpleQuery, 1216
**joomla root**/administrator/components/com_civicrm/civicrm/packages/DB/DataObject.php, query, 2394
**joomla root**/administrator/components/com_civicrm/civicrm/packages/DB/DataObject.php, _query, 442
**joomla root**/administrator/components/com_civicrm/civicrm/CRM/Core/BAO/Setting.php, find, 153
**joomla root**/administrator/components/com_civicrm/civicrm/CRM/Core/Config.php, retrieve, 345
**joomla root**/administrator/components/com_civicrm/civicrm/CRM/Core/Config.php, _initVariables, 183
**joomla root**/administrator/components/com_civicrm/admin.civicrm.php, singleton, 25
**joomla root**/administrator/components/com_civicrm/admin.civicrm.php, civicrm_init, 37
**joomla root**/administrator/components/com_civicrm/admin.civicrm.php, civicrm_invoke, 22
**joomla root**/libraries/joomla/application/component/helper.php, require_once, 162
**joomla root**/administrator/includes/application.php, renderComponent, 136
**joomla root**/administrator/index.php, dispatch, 67
**joomla root**/administrator/index2.php, include, 14

Sorry. A non-recoverable error has occurred. The error trace below might help to resolve the issue

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

    [code] => -19
    [message] => DB Error: no such field
    [mode] => 16
    [debug_info] => SELECT  config_backend, locales 
 FROM civicrm_domain
 
 
 
 
 
 [nativecode=1054 ** Unknown column 'locales' in 'field list']
    [type] => DB_Error
    [user_info] => SELECT  config_backend, locales 
 FROM civicrm_domain
 

 [nativecode=1054 ** Unknown column 'locales' in 'field list']
    [to_string] => [db_error: message="DB Error: no such field" code=-19 mode=callback callback=CRM_Core_Error::handle prefix="" info="SELECT  config_backend, locales 
 FROM civicrm_domain
   
 [nativecode=1054 ** Unknown column 'locales' in 'field list']"]
)

[/code]

Michał Mach

  • Ask me questions
  • ****
  • Posts: 748
  • Karma: 59
    • CiviCRM site
  • CiviCRM version: latest
  • CMS version: Drupal and Joomla latest
  • MySQL version: numerous
  • PHP version: 5.3 and 5.2
Re: Database upgrade step fails 2.0.2 ---> 2.1.0 Joomla 1.5.9
March 19, 2009, 03:26:02 am
Hey,

Adding "locales" field in civicrm_domain is a part of 2.1 upgrade process. The fact that you're getting "Unknown column 'locales' in 'field list'" error indeed means that 2.1 upgrade process failed, but doesn't give a hint where did it happen. Did you get any specific error during 2.0.2 -> 2.1 upgrade or just a message that database upgrade step failed?

Thx,
m
Found this reply helpful? Contribute NOW and help us improve CiviCRM with the Make it Happen! initiative.

My absolute favourite: Wordpress Integration!.

Donate Now!

Deepak Srivastava

  • Moderator
  • Ask me questions
  • *****
  • Posts: 677
  • Karma: 65
Re: Database upgrade step fails 2.0.2 ---> 2.1.0 Joomla 1.5.9
March 19, 2009, 06:38:19 am
mrnoah,

Quote
Database consistency check failed. FK constraint names not in the required format. Please rebuild your 2.0 database to ensure schema integrity.

The error indicates that something is wrong with the structure of db (specially constraint format).
The solution is to rebuild your 2.0 db -
1. create a new database with the structure from the file "civicrm_20_codebase/sql/civicrm.mysql".
2. Import ONLY data FROM your 2.0db TO newly created database in previous step.
Found this reply helpful? Contribute NOW and help us improve CiviCRM with the Make it Happen! initiative.

mrnoah

  • Guest
Re: Database upgrade step fails 2.0.2 ---> 2.1.0 Joomla 1.5.9
March 19, 2009, 10:16:36 am
Ok. That sounds fairly straightforward.  I just make a fresh DB that has the correct structure and i put my data in it. I'll try it out.

- Noah

Pages: [1]
  • CiviCRM Community Forums (archive) »
  • Old sections (read-only, deprecated) »
  • Support »
  • Upgrading CiviCRM (Moderator: Deepak Srivastava) »
  • Database upgrade step fails 2.0.2 ---> 2.1.0 Joomla 1.5.9

This forum was archived on 2017-11-26.