The connection and login worked and the database exists, but the table you asked for isn’t in it. The message names both the database and the table, which is your best clue: in the example, cpuser_shop is the database and wp_options the table. In Laravel it usually reads:
SQLSTATE[42S02]: Base table or view not found: 1146 Table 'cpuser_shop.users' doesn't exist
Causes
- An incomplete import: the import stopped on file size or a timeout, so only some tables arrived.
- A wrong table prefix:
wp-config.phpsays$table_prefix = 'wp_';but the tables start withwpx7_. - Letter case: on Linux,
Usersandusersare different tables. A dump exported on Windows may have lowercase names while the code uses capitals. - The wrong database: your config points to an old or empty database.
- Migrations not run on a freshly deployed Laravel project.
- A damaged table: its files are missing, often with error
1932 Table doesn't exist in engine.
How to fix it
- List the tables that exist, by selecting the database in phpMyAdmin’s sidebar or in the SQL tab:
SHOW TABLES;
SHOW TABLES LIKE '%options';
-
Compare the database name in the error with
DB_DATABASEorDB_NAMEin your config, and correct it if it differs. -
Fix the WordPress prefix. If the tables start with
wpx7_, set this in wp-config.php:
$table_prefix = 'wpx7_';
- Finish an incomplete import. Check that the dump actually contains the missing table:
grep -c "CREATE TABLE" backup.sql
grep "CREATE TABLE \`wp_options\`" backup.sql
Then import the whole file into an empty database. If it’s large and keeps stopping, see phpMyAdmin import file too large.
- Make the case match. Rename the table to match the code, or change the code to match the table:
RENAME TABLE Users TO users;
- Run Laravel migrations over SSH:
php artisan migrate:status
php artisan migrate --force
--force is needed because Laravel won’t run migrations in production without confirmation.
- For a damaged table reporting
Table doesn't exist in engine, don’t copy database files around by hand; restore the database from a backup.
Prevention
- After every import, compare the table count between source and destination.
- Always use lowercase table names.
- Make
php artisan migrate --forcea fixed deployment step, as in the Laravel deployment guide. - When moving WordPress, move
wp-config.phptogether with its database, or follow the WordPress migration guide.
On ArabyHost
Databases run on MariaDB/MySQL with phpMyAdmin, so you can inspect tables and run the queries above from your browser. AI/Developer plans add SSH for the artisan and grep commands; on other plans, phpMyAdmin covers the database side. Daily JetBackup backups let you restore a whole database if a table is damaged. If you’re not sure which table your site is asking for, the Araby AI assistant reads your error log and explains the cause.
FAQ
Why does the table work on my machine but not on the server?
Usually letter case. On Windows and macOS, MySQL treats Users and users as the same table by default; on Linux they're different. Use lowercase table names in both the database and your code.
I moved a WordPress site and now get this error. Why?
Check $table_prefix in wp-config.php and confirm every table was imported. If the tables start with something other than wp_, put that exact prefix in the file.
What does Table doesn't exist in engine mean?
That's error 1932: MySQL knows the table's name but InnoDB can't find its data, usually because of corruption or files copied incompletely. The safe fix is restoring the database from a backup.