Page 1 of 1

Could not load database adaptor mysql!! again

Posted: Sat May 25, 2024 10:16 am
by GeekScum
Trying to get a friends install working again.
Open Cart Version 1.5.6.4 -> 4.0.2.3
PHP Version 8.0
MySQL 5.7
Was on version 1.5.6.4 and after an automatic php upgrade by hosting site was no longer fully functional. Tried upgrading to OpenCart version 3.0.3.9 and got a blank screen at sitename.com/install and an error in the log indicating could not load database adapter. Tried upgrading to 4.0.2.3 same problem but now at least I get the following error message "Error: Could not load database adaptor mysql!!: in /home2/product1/public_html/system/library/db.php on line 36"

I dug through other posts related to this but haven't been able to find a solution that works. Appreciate any help, thanks.

Re: Could not load database adaptor mysql!! again

Posted: Sun May 26, 2024 8:09 am
by straightlight
GeekScum wrote:
Sat May 25, 2024 10:16 am
Trying to get a friends install working again.
Open Cart Version 1.5.6.4 -> 4.0.2.3
PHP Version 8.0
MySQL 5.7
Was on version 1.5.6.4 and after an automatic php upgrade by hosting site was no longer fully functional. Tried upgrading to OpenCart version 3.0.3.9 and got a blank screen at sitename.com/install and an error in the log indicating could not load database adapter. Tried upgrading to 4.0.2.3 same problem but now at least I get the following error message "Error: Could not load database adaptor mysql!!: in /home2/product1/public_html/system/library/db.php on line 36"

I dug through other posts related to this but haven't been able to find a solution that works. Appreciate any help, thanks.
At this stage, better to install a fresh version of OC v4.0.2.3 and integrate your database data afterwards rather than running the upgrade since, most likely, v1.5x releases won't be compatible with v4.x releases by simply running the wizard.

Re: Could not load database adaptor mysql!! again

Posted: Sun May 26, 2024 6:33 pm
by JNeuhoff
As said here, better to do a fresh install. And use MySql 8 DB server, along with a PHP 8.x version.

Re: Could not load database adaptor mysql!! again

Posted: Sun May 26, 2024 9:08 pm
by ADD Creative
The mysql extension was removed in PHP 7. You need to use mysqli. You should be able to change DB_DRIVER in the config.php and admin/config.php.