Unable to Create Book after import. #552

Closed
opened 2026-02-04 20:57:07 +03:00 by OVERLORD · 1 comment
Owner

Originally created by @aewald303 on GitHub (Jan 22, 2018).

For Bug Reports

  • BookStack Version (Found in settings, Please don't put 'latest'): 19
  • PHP Version: 7.0.22
  • MySQL Version: 5.7.2
Expected Behavior

Able to create a new book via the web UI.

Current Behavior

When submitting the book for creation users are greeted with 500 Internal Server Error.

Steps to Reproduce

After following backup and import guide. Everything seems to work great. I can create chapters/pages without Issue but unable to create books. After turning on debug and checking logs. This is what I have found so far.

Stack trace:
#0 /var/www/bookstack/storage/framework/views/331c928a9bfd10f199fc390c413c0d7ed2387264.php(7): Illuminate\Foundation\Bootstrap\HandleExceptions->handleError(8, 'Undefined varia...', '/var/www/bookst...', 7, Array)
#1 /var/www/bookstack/vendor/laravel/framework/src/Illuminate/View/Engines/PhpEngine.php(43): include('/var/www/bookst...')
#2 /var/www/bookstack/vendor/laravel/framework/src/Illuminate/View/Engines/CompilerEngine.php(59): Illuminate\View\Engines\PhpEngine->evaluatePath('/var/www/bookst...', Array)
#3 /var/www/bookstack/vendor/laravel/framework/src/Illuminate/View/View.php(137): Illuminate\View\Engines\CompilerEngine->get('/var/www/bookst...', Array)
#4 /var/www/bookstack/vendor/laravel/framework/src/Illuminate/View/View.php(120): Illuminate\View\View->getContents()
#5 /var/www/bookstack/vendor/laravel/framew...
PHP message: PHP Fatal error: Uncaught ErrorException: Undefined variable: message in /var/www/bookstack/storage/framework/views/331c928a9bfd10f199fc390c413c0d7ed2387264.php:7

"SQLSTATE[42S22]: Column not found: 1054 Unknown column 'image_id' in 'field list' (SQL: insert into books (name, description, image_id, slug, created_by, updated_by, updated_at, created_at) values (test book, , http://MYFQDN/book_default_cover.png, test-book, 4, 4, 2018-01-22 15:18:31, 2018-01-22 15:18:31))

Originally created by @aewald303 on GitHub (Jan 22, 2018). ### For Bug Reports * BookStack Version *(Found in settings, Please don't put 'latest')*: 19 * PHP Version: 7.0.22 * MySQL Version: 5.7.2 ##### Expected Behavior Able to create a new book via the web UI. ##### Current Behavior When submitting the book for creation users are greeted with 500 Internal Server Error. ##### Steps to Reproduce After following backup and import guide. Everything seems to work great. I can create chapters/pages without Issue but unable to create books. After turning on debug and checking logs. This is what I have found so far. Stack trace: #0 /var/www/bookstack/storage/framework/views/331c928a9bfd10f199fc390c413c0d7ed2387264.php(7): Illuminate\Foundation\Bootstrap\HandleExceptions->handleError(8, 'Undefined varia...', '/var/www/bookst...', 7, Array) #1 /var/www/bookstack/vendor/laravel/framework/src/Illuminate/View/Engines/PhpEngine.php(43): include('/var/www/bookst...') #2 /var/www/bookstack/vendor/laravel/framework/src/Illuminate/View/Engines/CompilerEngine.php(59): Illuminate\View\Engines\PhpEngine->evaluatePath('/var/www/bookst...', Array) #3 /var/www/bookstack/vendor/laravel/framework/src/Illuminate/View/View.php(137): Illuminate\View\Engines\CompilerEngine->get('/var/www/bookst...', Array) #4 /var/www/bookstack/vendor/laravel/framework/src/Illuminate/View/View.php(120): Illuminate\View\View->getContents() #5 /var/www/bookstack/vendor/laravel/framew... PHP message: PHP Fatal error: Uncaught ErrorException: Undefined variable: message in /var/www/bookstack/storage/framework/views/331c928a9bfd10f199fc390c413c0d7ed2387264.php:7 "SQLSTATE[42S22]: Column not found: 1054 Unknown column 'image_id' in 'field list' (SQL: insert into `books` (`name`, `description`, `image_id`, `slug`, `created_by`, `updated_by`, `updated_at`, `created_at`) values (test book, , http://MYFQDN/book_default_cover.png, test-book, 4, 4, 2018-01-22 15:18:31, 2018-01-22 15:18:31))
Author
Owner

@aewald303 commented on GitHub (Jan 22, 2018):

Colleague of mine suggested running these commands again.

php artisan migrate
php artisan cache:clear
php artisan view:clear

This fixed the issue.

@aewald303 commented on GitHub (Jan 22, 2018): Colleague of mine suggested running these commands again. php artisan migrate php artisan cache:clear php artisan view:clear This fixed the issue.
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/BookStack#552