-
-
Notifications
You must be signed in to change notification settings - Fork 1.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Problem generating model helpers, as database has MySQL 5.7 JSON/JSONB column types #295
Comments
@ddctd143 Did you figure out a solution for this? |
I found this pull request on DBAL, which indicates that MySQL 5.7.8 is the specific version that JSON became available in, but the PR has not been merged yet, so this might be an upstream problem that we have to wait for... |
I'm with same issue, anyone knows a way to ignore this error and generate ide-helper:model ? |
Couldn't in theory require our own version of dbal with that pull request merged? And then set the repo in the composer.json of this lib? So far in my testing dbal with that pull request seems to work fine. |
Has this been fixed? I'm getting the same error message using Laravel 5.2, Mysql 5.7.13 and php 7.0.* |
No. |
I have added the following in 'custom_db_types' => array(
'mysql' => [
'json' => 'text',
],
), In /**
* @property array $data
*/ |
Actually 'custom_db_types' => array(
'mysql'=> [
'json'=>'json_array'
]
), works just as well 😄 |
@barryvdh the correct solution is the last comment (to use |
I have upgraded to Laravle 5.2 to use Schema builder with $table->json(...) ability.
DBAL from version 2.5 has support for new json field types in Doctrine\DBAL\Platforms\MySQL57Platform class which extends default MySqlPlatform class.
The text was updated successfully, but these errors were encountered: