Skip to content

Mysql2::Error: BLOB, TEXT, GEOMETRY or JSON column 'metadata' can't have a default value #9

@estebanutz

Description

@estebanutz

I ran into this issue while running the migrations:

Mysql2::Error: BLOB, TEXT, GEOMETRY or JSON column 'metadata' can't have a default value

I'm running rails 8.0.1, mysql2 0.5.6 gem, and my local mysql is 8.4.4 for what I found from version 8.0.13 onwards

The BLOB, TEXT, GEOMETRY, and JSON data types can be assigned a default value only if the value is written as an expression, even if the expression value is a literal.

Could it be an issue with the mysql2 gem? Any pointers, can I just remove the default values from the migration?

Thanks!

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions