Question

I am trying to follow a tutorial about the basics of Databases and i am at the part of setting up Sentry 2. I added all the exceptions as requested. But on step four of the documentation page on the Sentry 2 website. I am getting the following error

{"error":{"type":"ErrorException","message":"Undefined index: collation","file":"\/var\/www\/db_test\/vendor\/laravel\/framework\/src\/Illuminate\/Database\/Connectors\/MySqlConnector.php","line":22}}

I tried a few things as noted in my ssh screen but nothing:

    robert@Devlopement:/var/www/db_test$ php composer.phar update
Loading composer repositories with package information
Updating dependencies (including require-dev)
  - Installing cartalyst/sentry (dev-master 9a8221d)
    Downloading: 100%

Writing lock file
Generating autoload files
Generating optimized class loader
Compiling common classes
robert@Devlopement:/var/www/db_test$ php artisan key:generate
Application key [Dabb88Fw5080yq53cYgyprredmPbVBpK] set successfully.
robert@Devlopement:/var/www/db_test$ php artisan migrate --package=cartalyst/sentry
{"error":{"type":"ErrorException","message":"Undefined index: collation","file":"\/var\/www\/db_test\/vendor\/laravel\/framework\/src\/Illuminate\/Database\/Connectors\/MySqlConnector.php","line":22}}robert@Devlopement:/var/www/db_test$ phptrytisan migrate --package=cartalyst/sen
{"error":{"type":"ErrorException","message":"Undefined index: collation","file":"\/var\/www\/db_test\/vendor\/laravel\/framework\/src\/Illuminate\/Database\/Connectors\/MySqlConnector.php","line":22}}robert@Devlopement:/var/www/db_test$ ^C
robert@Devlopement:/var/www/db_test$ 

I Google the problem and it seems like it was an issue that was suppose to be resolved in beta. Any ideas?

Was it helpful?

Solution

Your database config is broken. In app/config/database.php is a list of configured databases. Yours is most likely missing 'collation' in your config.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top