MyBB Community Forums

Full Version: Won't display database contents
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Pages: 1 2
Hi!

I'm trying to move my board to my own server for self-hosting.

- I downloaded the latest version of myBB and installed it successfully. The Installation Wizard confirmed this. I set the file and directory permissions.
- I created an empty database in my server's CPanel and imported my board's database to it successfully. It confirmed it and everything's indeed definitely there when I check it from phpMyAdmin.
- Table prefix name in the config.php file matches the Tables' name in the imported database.

Yet it does not display my board at all. It's as if I simply created a brand-new board instead of importing a database with content. What am I missing?

-link removed after problem solved-
Have you checked that inc/config.php is pointing towards the right database? That's the only way something like this would happen, or if the database you moved was blank.
Yes it is pointing to the correct database in that file.
But I just noticed, it appears that in the cPanel when I click phpMyAdmin and then the database in question it is perfectly fine--all the content is there. But when I click on MySQL Databases and look at the Current Databases list--it claims that the database in question is empty. Why, when all the content is there though the phpMyAdmin section??

Or is this no longer a myBB problem but something I need to solve with my server host?

Sorry if any of these questions are dumb. I have never ever attempted anything like this before.
You don't need to install the newest version of mybb. Simply move your DB, Files, and change some settings.

1. create a DB on the new host
2. import your current forum DB into the newly created DB on the new host
3. upload files to the new host
4. set DB config, settings to reflect the new database on the new host

There should be plenty of how to's if you search around Smile
Thanks, but I did all that already. It appears the database in question claims to be empty in one section of my cPanel though phpMyAdmin definitely shows all the content intact. Does anybody happen to know why that might be?

It's probably something small I keep overlooking.
(2018-05-28, 07:30 PM)NIBS Wrote: [ -> ]Thanks, but I did all that already. It appears the database in question claims to be empty in one section of my cPanel though phpMyAdmin definitely shows all the content intact. Does anybody happen to know why that might be?

It's probably something small I keep overlooking.

Interesting. I'd suggest deleting the database and recreating it. From there it may be worthwhile opening your .sql backup file, copy and pasting it into query and running the query instead of using the import tool. That way, you'll immediately know if the database gets uploaded correctly or not.
Okay, so I did that. And it shows me green message with the "OK" symbol and says "# MySQL returned an empty result set (i.e. zero rows)."

So...It should be okay? Yet it doesn't show the database.

Also another annoying problem is that every time I delete and recreate the database the myBB Installation Wizard claims that I don't have the latest version of myBB and won't let me browse the board but wants me to upgrade it even though of course I have the latest version since I started the whole damn process by downloading the latest version. Confused
(2018-05-29, 03:05 PM)NIBS Wrote: [ -> ]Okay, so I did that. And it shows me green message with the "OK" symbol and says "# MySQL returned an empty result set (i.e. zero rows)."

So...It should be okay? Yet it doesn't show the database.

Also another annoying problem is that every time I delete and recreate the database the myBB Installation Wizard claims that I don't have the latest version of myBB and won't let me browse the board but wants me to upgrade it even though of course I have the latest version since I started the whole damn process by downloading the latest version. Confused

If it returned "zero rows" that means your backup is empty or somehow corrupt. If it's a .sql extension file, I'd suggest opening up your backup file in notepad and see if it's contents are still there.

On another note, how did you backup your database initially?
The contents are there, and again they do show up in phpMyAdmin for that database.

I'm moving from IcyBoards so the initial backup was done by a robot. It compressed the database into a GZ format and then I downloaded it and imported it to my server. And now extracted it with 7-Zip to do that query thing.
What do you mean by "the contents are there"? By the sounds of it, you've only imported the table structure (i.e mybb_users table etc.) and not any actual values hence why there's no rows. Can you run the following query, that'll let me know if there are any values:#

SELECT uid FROM mybb_users WHERE uid = 1;

The query assumes that you have a user with a uid of 1. If the UID 1 isn't returned that means that your backup more than likely only contains table structure with 0 values.
Pages: 1 2