Skip to content
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

Use cakephp/database for mysql schema #796

Merged
merged 2 commits into from
Jan 3, 2025
Merged

Use cakephp/database for mysql schema #796

merged 2 commits into from
Jan 3, 2025

Conversation

markstory
Copy link
Member

Use the schema reflection logic present in cakephp/database instead of
having another copy of it in migrations.

I've also fixed some quoting method usage and updated to php8 syntax.

I'll split the changes for pending migrations out. The tests as written didn't run for me locally as I have a different database name. I also wanted to clean up the additional output generated by test setup.

Use the schema reflection logic present in cakephp/database instead of
having another copy of it in migrations.

I've also fixed some quoting method usage and updated to php8 syntax.
(id INT(11) NOT NULL)
ENGINE = InnoDB CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci";
$this->adapter->execute($sql);
$this->assertTrue($this->adapter->hasTable('discouraged.naming.convention'));
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't see a reason to continue supporting table names with. as they aren't well supported by cakephp/database either.

$table->addColumn('column1', 'string');
$table->save();

$described = $this->adapter->describeTable('t');
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This method had no callers and is being removed.

@markstory markstory merged commit d9b6140 into 4.next Jan 3, 2025
20 checks passed
@markstory markstory deleted the mysql-schema branch January 3, 2025 17:55
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