MyBB Community Forums

Full Version: MyBB has experienced an internal SQL error
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
So recently, due to fuckups of my hosting provider, i lost my mybb forum, but luckily I had a 2 months old database backup. So I installed the fresh mybb copy, dropped all the newly created data from database and imported my old database. But I keep getting"MyBB has experienced an internal SQL error and cannot continue." Even tho, the database details are correct in inc/config.php
Can you edit ./inc/settings.php, find the row that has "errortypemedium", change the value to "both", and save the file? It should show more details about the error.
(2021-03-06, 07:52 PM)Matt Wrote: [ -> ]Can you edit ./inc/settings.php, find the row that has "errortypemedium", change the value to "both", and save the file? It should show more details about the error.

Apparently, it says Your board has not yet been upgraded. Please do so before attempting to browse it. Tho I installed the latest mybb and restored the database after installation. 
You don't need to install the latest version first, doing that and then restoring your old database means you'll just have the same database you started with again. You need to run the upgrade script at ./install/upgrade.php.
You mean I should install the old version of mybb that my database was using and then upgrade it later?
No, you don't need to install a fresh version of anything.

"Installing" just creates the database tables, you already have that, so what you've done so far is started with a 1.6 database, installed 1.8 which gives you a clean 1.8 database, and then you've restored the 1.6 backup, so the database is the same as it was before you started.

You just need to upload the 1.8 files over the 1.6 files and run the upgrade script.
I wasn't using 1.6 at all. It was 1.8.23 or 1.8.24, I don't remember exactly. Is there any way to find that out through the database?
Ah, sorry my bad, I was getting mixed up with another thread.

In that case then you still just need to run the upgrade script, it should give you the option of picking your old version from a dropdown but it usually has the old version pre-selected.
I still did not understand. I mentioned in my first post that I do not have the backup of files. I just have the database backup. Now how exactly do I use to restore my forum data?
EDIT: Had to install 1.8.22 (Same version as database backup), deleted all the data in database and imported the backup which worked.
That's what I was trying to say, you didn't need to reinstall anything at all, it's a completely unnecessary step. If you delete the data and import a backup, then you're replacing all the tables the installer just created, thus it was pointless running it - you'd still have an older database that still need to be upgraded. All you had to do was upload the 1.8.25 over your existing files (or just upload fresh) and run the upgrade script - that was it. Installing a brand new clean forum first is not and has never been necessary. If you're upgraded now then that's good but it sounds like a lot of unnecessary steps were taken to get there.