framework icon indicating copy to clipboard operation
framework copied to clipboard

[9.x] fix mySQL enum support for db:show command

Open lupinitylabs opened this issue 3 years ago • 0 comments

The Issue

Currently, the new db:show console command throws a Doctrine\DBAL\Exception if any table in the application uses ENUM columns on a MySQL database:

grafik

The Fix

The Doctrine Project addresses the issue with MySQL ENUMs in their documentation and as a global workaround suggests mapping the type to VARCHARs to mitigate the issue.

This PR registers such a type mapping dynamically within the command for all MySQL platforms.

Further unsupported types

The same problem exists for POINT types, but I first wanted to see if there is an intent to address these issues. If the fix is appreciated, I'm happy to add one for POINTs too.

lupinitylabs avatar Aug 10 '22 20:08 lupinitylabs

I noticed a pull request has been opened to address this in the meantime, I am closing this for now in favor of #43635.

lupinitylabs avatar Aug 10 '22 20:08 lupinitylabs