Skip to content

Add test case to show collation issue in MysqlAdapter::createTable()#1020

Open
ishanvyas22 wants to merge 1 commit intocakephp:4.xfrom
ishanvyas22:feature/PB-49136_Collation-issue
Open

Add test case to show collation issue in MysqlAdapter::createTable()#1020
ishanvyas22 wants to merge 1 commit intocakephp:4.xfrom
ishanvyas22:feature/PB-49136_Collation-issue

Conversation

@ishanvyas22
Copy link

When collation is set on field the createTable() generates wrong sql which leads to wrong collation on the field when table is created. This issue is seems to be present from v4.6 where $this->getColumnSqlDefinition() changed to $dialect->columnDefinitionSql() in MysqlAdapter file (#839). The weird part is there's no direct test case which tests the createMethod(), may be there's a reason for that but then this scenario should've covered.

This PR adds a test case to only demonstrate the issue present. I have not applied any fix since I'm not sure which place would be the right place to fix it.

When collation is set on field the createTable() generates wrong sql which leads to wrong collation on the field when table is created.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant