1

We have a little bit of a strange issue and could use some input.

We are using CiviCRM on Joomla. Started on Joomla 1.5 years ago, then upgraded to J2.5/CiviCRM 4.4 a couple years ago, then a few weeks ago upgraded to J3.4/CiviCRM 4.7.1.

Somehow, somewhere along the way over the past couple years during multiple Joomla and CiviCRM upgrades, the site got configured so that Joomla was using one database (deafhhny_jmlprod) and CiviCRM was using a different database (deafhhny_jmlnew). It seems to have been working fine all this time and nobody noticed. Then during the latest upgrades, the CiviCRM config file got updated to point to the same DB Joomla uses (deafhhny_jmlprod). We noticed in the CiviCRM dashboard that we were missing the last couple years of data. I poked around and figured out that the data is in the deafhhny_jmlnew database, and that the civicrm.settings.php file had changed during the upgrade.

Before I just change the CiviCRM config file to point to the deafhhny_jmlnew database like it was before, I wanted to check with the community to find out if there could be any adverse effects to doing that.

If not, then I should be able to just update the database strings in civicrm.settings.php to point to deafhhny_jmlnew like it was before, right? Although, I'm not sure if that DB got upgraded during the 4.4 to 4.7.1 upgrade process or what will happen if I point CiviCRM to it now. Any ideas?

If there are potential issues with pointing to a different DB, can I get some help with how to get the data from the _jmlnew database into the _jmlprod database properly without breaking anything?

Thanks.

1

First - everything I suggest, do on a dev site, and make backups!

You SHOULD be able to just change civicrm.settings.php to point to @deafhhny_jmlnew@, then run the upgrade script, which upgrades the database to match the installed version. Make sure you're logged into Joomla before you do this - going so many versions ahead, you're likely to be unable to do pretty much anything in Joomla/Civi (including log in) except go to the upgrade script page.

0

I would be really surprised if nothing changed in the DB schema between 4.4 and 4.7, although I don't know for certain. 4.2 to 4.4 had some quite dramatic changes WRT activity storage, for instance.

My suggestion would be to move the data across, as much as you can. Use PhpMyAdmin (or similar) to download the data in the DB as a CSV, and then use CiviCRM's import feature. Failing that directly insert the rows into the table.

0

I tried out Jon G's suggestion in a dev environment and it seems to have worked well. I made sure I was logged into the Joomla admin panel, changed the civicrm.settings.php files in both admin and component directories to point to the separate CiviCRM database, and then pointed my browser directly to the CiviCRM database upgrade URL. The DB upgrade went smoothly and now I can see the correct data.

I'm about to follow the same process in the live website environment. Assuming it works the same way there, I think I'll just leave it like that rather than trying to import the data into a single database.

Thanks for the help.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.